public class Tuple
extends java.lang.Object
implements java.io.Serializable
Modifier and Type | Field and Description |
---|---|
private static long |
serialVersionUID |
Constructor and Description |
---|
Tuple(TupleDesc td)
Create a new tuple with the specified schema (type).
|
Modifier and Type | Method and Description |
---|---|
java.util.Iterator<Field> |
fields() |
Field |
getField(int i) |
RecordId |
getRecordId() |
TupleDesc |
getTupleDesc() |
void |
resetTupleDesc(TupleDesc td)
reset the TupleDesc of thi tuple
|
void |
setField(int i,
Field f)
Change the value of the ith field of this tuple.
|
void |
setRecordId(RecordId rid)
Set the RecordId information for this tuple.
|
java.lang.String |
toString()
Returns the contents of this Tuple as a string.
|
private static final long serialVersionUID
public Tuple(TupleDesc td)
td
- the schema of this tuple. It must be a valid TupleDesc
instance with at least one field.public TupleDesc getTupleDesc()
public RecordId getRecordId()
public void setRecordId(RecordId rid)
rid
- the new RecordId for this tuple.public void setField(int i, Field f)
i
- index of the field to change. It must be a valid index.f
- new value for the field.public Field getField(int i)
i
- field index to return. Must be a valid index.public java.lang.String toString()
toString
in class java.lang.Object
public java.util.Iterator<Field> fields()
public void resetTupleDesc(TupleDesc td)