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