|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.crunch.types.writable.TupleWritable
public class TupleWritable
A straight copy of the TupleWritable implementation in the join package, added here because of its package visibility restrictions.
Constructor Summary | |
---|---|
TupleWritable()
Create an empty tuple with no allocated storage for writables. |
|
TupleWritable(org.apache.hadoop.io.Writable[] vals)
Initialize tuple with storage; unknown whether any of them contain "written" values. |
Method Summary | |
---|---|
void |
clearWritten()
Clear any record of which writables have been written to, without releasing storage. |
void |
clearWritten(int i)
Record that the tuple does not contain an element at the position provided. |
int |
compareTo(TupleWritable o)
|
boolean |
equals(Object other)
|
org.apache.hadoop.io.Writable |
get(int i)
Get ith Writable from Tuple. |
boolean |
has(int i)
Return true if tuple has an element at the position provided. |
int |
hashCode()
|
void |
readFields(DataInput in)
|
void |
setWritten(int i)
Record that the tuple contains an element at the position provided. |
int |
size()
The number of children in this Tuple. |
String |
toString()
Convert Tuple to String as in the following. |
void |
write(DataOutput out)
Writes each Writable to out . |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public TupleWritable()
public TupleWritable(org.apache.hadoop.io.Writable[] vals)
Method Detail |
---|
public boolean has(int i)
public org.apache.hadoop.io.Writable get(int i)
public int size()
public boolean equals(Object other)
equals
in class Object
public int hashCode()
hashCode
in class Object
public String toString()
toString
in class Object
public void write(DataOutput out) throws IOException
out
. TupleWritable format:
<count><type1><type2>...<typen><obj1><obj2>...<objn>
write
in interface org.apache.hadoop.io.Writable
IOException
public void readFields(DataInput in) throws IOException
readFields
in interface org.apache.hadoop.io.Writable
IOException
public void setWritten(int i)
public void clearWritten(int i)
public void clearWritten()
public int compareTo(TupleWritable o)
compareTo
in interface Comparable<TupleWritable>
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |