Move the class to engine
[proteocache.git] / engine / compbio / engine / Pair.java
diff --git a/engine/compbio/engine/Pair.java b/engine/compbio/engine/Pair.java
new file mode 100644 (file)
index 0000000..efd24c7
--- /dev/null
@@ -0,0 +1,24 @@
+package compbio.engine;
+
+public class Pair<K, V> {
+
+       private final K element0;
+       private final V element1;
+
+       public static <K, V> Pair<K, V> createPair(K element0, V element1) {
+               return new Pair<K, V>(element0, element1);
+       }
+
+       public Pair(K element0, V element1) {
+               this.element0 = element0;
+               this.element1 = element1;
+       }
+
+       public K getElement0() {
+               return element0;
+       }
+
+       public V getElement1() {
+               return element1;
+       }
+}
\ No newline at end of file