All Downloads are FREE. Search and download functionalities are using the official Maven repository.

xapi.collect.impl.StringDictionaryDefault Maven / Gradle / Ivy

There is a newer version: 0.5
Show newest version
package xapi.collect.impl;

import xapi.collect.api.StringDictionary;
import xapi.util.api.ReceivesValue;

public class StringDictionaryDefault  extends StringToAbstract implements StringDictionary{

  @Override
  public boolean hasValue(String key) {
    return containsKey(key);
  }

  @Override
  public V getValue(String key) {
    return get(key);
  }

  @Override
  public V setValue(String key, V value) {
    return put(key, value);
  }

  @Override
  public V removeValue(String key) {
    return remove(key);
  }

  @Override
  public void clearValues() {
    clear();
  }

  @Override
  public void forKeys(ReceivesValue receiver) {
    for (String key : keyArray()) {
      receiver.set(key);
    }
  }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy