List of usage examples for org.apache.hadoop.io ShortWritable equals
@Override public boolean equals(Object o)
o
is a ShortWritable with the same value. From source file:com.axiomine.largecollections.turboutil.ShortWritableList.java
License:Apache License
@Override public int indexOf(Object o) { int index = -1; int myIndex = -1; Iterator<ShortWritable> iter = this.iterator(); while (iter.hasNext()) { index++;// ww w . j a va2s .c o m ShortWritable e = iter.next(); if (e.equals(o)) { myIndex = index; break; } } return myIndex; }
From source file:com.axiomine.largecollections.turboutil.ShortWritableList.java
License:Apache License
@Override public int lastIndexOf(Object o) { int index = -1; int myIndex = -1; Iterator<ShortWritable> iter = this.iterator(); while (iter.hasNext()) { index++;/*w ww . ja va2 s .c om*/ ShortWritable e = iter.next(); if (e.equals(o)) { myIndex = index; } } return myIndex; }