rinde.sim.util.Tuple Maven / Gradle / Ivy
package rinde.sim.util;
import java.util.Map.Entry;
/**
* @author Rinde van Lon ([email protected])
*/
@Deprecated
public class Tuple implements Entry {
protected K key;
protected V value;
public Tuple(K key, V value) {
this.key = key;
this.value = value;
}
@Override
public K getKey() {
return key;
}
@Override
public V getValue() {
return value;
}
@Override
public V setValue(V value) {
return this.value = value;
}
public static Entry copy(Entry entry) {
return new Tuple(entry.getKey(), entry.getValue());
}
}