public class ArrayListOfFloatsWritable extends ArrayListOfFloats implements org.apache.hadoop.io.WritableComparable<ArrayListOfFloatsWritable>
ArrayListOfFloats class. This class provides an efficient data
structure to store a list of floats for MapReduce jobs.array, size| Constructor and Description |
|---|
ArrayListOfFloatsWritable()
Constructs an ArrayListOfFloatsWritable object.
|
ArrayListOfFloatsWritable(ArrayListOfFloatsWritable other)
Constructs a deep copy of the ArrayListOfFloatsWritable object given as parameter.
|
ArrayListOfFloatsWritable(float[] arr)
Constructs a list from an array.
|
ArrayListOfFloatsWritable(int initialCapacity)
Constructs an empty list with the specified initial capacity.
|
| Modifier and Type | Method and Description |
|---|---|
int |
compareTo(ArrayListOfFloatsWritable obj)
Elementwise comparison.
|
static ArrayListOfFloatsWritable |
fromArrayListOfFloats(ArrayListOfFloats a)
Creates a Writable version of this list.
|
void |
readFields(DataInput in)
Deserializes this object.
|
String |
toString() |
void |
write(DataOutput out)
Serializes this object.
|
add, add, addUnique, clear, clone, contains, ensureCapacity, equals, get, getArray, indexOf, intersection, isEmpty, iterator, lastIndexOf, merge, remove, set, setSize, shiftLastNToTop, size, sort, subList, toString, trimToSizepublic ArrayListOfFloatsWritable()
public ArrayListOfFloatsWritable(int initialCapacity)
initialCapacity - the initial capacity of the listpublic ArrayListOfFloatsWritable(ArrayListOfFloatsWritable other)
other - object to be copiedpublic ArrayListOfFloatsWritable(float[] arr)
arr - source arraypublic void readFields(DataInput in) throws IOException
readFields in interface org.apache.hadoop.io.Writablein - source for raw byte representationIOExceptionpublic void write(DataOutput out) throws IOException
write in interface org.apache.hadoop.io.Writableout - where to write the raw byte representationIOExceptionpublic String toString()
toString in class ArrayListOfFloatspublic static ArrayListOfFloatsWritable fromArrayListOfFloats(ArrayListOfFloats a)
public int compareTo(ArrayListOfFloatsWritable obj)
compareTo in interface Comparable<ArrayListOfFloatsWritable>obj - other object this is compared againstCopyright © 2014. All rights reserved.