Package org.apache.hadoop.io
Class TwoDArrayWritable
java.lang.Object
org.apache.hadoop.io.TwoDArrayWritable
- All Implemented Interfaces:
Writable
A Writable for 2D arrays containing a matrix of instances of a class.
-
Constructor Summary
ConstructorsConstructorDescriptionTwoDArrayWritable(Class valueClass) TwoDArrayWritable(Class valueClass, Writable[][] values) -
Method Summary
Modifier and TypeMethodDescriptionWritable[][]get()voidreadFields(DataInput in) Deserialize the fields of this object fromin.voidtoArray()voidwrite(DataOutput out) Serialize the fields of this object toout.
-
Constructor Details
-
TwoDArrayWritable
-
TwoDArrayWritable
-
-
Method Details
-
toArray
-
set
-
get
-
readFields
Description copied from interface:WritableDeserialize the fields of this object fromin.For efficiency, implementations should attempt to re-use storage in the existing object where possible.
- Specified by:
readFieldsin interfaceWritable- Parameters:
in-DataInputto deseriablize this object from.- Throws:
IOException- any other problem for readFields.
-
write
Description copied from interface:WritableSerialize the fields of this object toout.- Specified by:
writein interfaceWritable- Parameters:
out-DataOuputto serialize this object into.- Throws:
IOException- any other problem for write.
-