/** {@inheritDoc} */ @Override public void setAttribute(Object key, @Nullable Object val) { A.notNull(key, "key"); synchronized (attrs) { attrs.put(key, val); } }
/** {@inheritDoc} */ @SuppressWarnings("unchecked") @Override public <K, V> V getAttribute(K key) { A.notNull(key, "key"); synchronized (attrs) { return (V) attrs.get(key); } }
/** {@inheritDoc} */ @Override public GridFuture<?> addData(Map<K, V> entries) throws IllegalStateException { A.notNull(entries, "entries"); return addData(entries.entrySet()); }
/** {@inheritDoc} */ @SuppressWarnings({"unchecked"}) @Override public <T> T attribute(String name) { return (T) attrs.get(name); }