public class DefaultTuple extends AbstractTuple
| Modifier and Type | Class and Description |
|---|---|
static class |
DefaultTuple.DefaultTupleRawComparator |
| Modifier and Type | Field and Description |
|---|---|
protected java.util.List<java.lang.Object> |
mFields |
| Constructor and Description |
|---|
DefaultTuple()
Default constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
append(java.lang.Object val)
Append a field to a tuple.
|
int |
compareTo(java.lang.Object other) |
java.lang.Object |
get(int fieldNum)
Get the value in a given field.
|
java.util.List<java.lang.Object> |
getAll()
Get all of the fields in the tuple as a list.
|
static java.lang.Class<? extends TupleRawComparator> |
getComparatorClass() |
long |
getMemorySize()
Determine the size of tuple in memory.
|
int |
hashCode() |
void |
readFields(java.io.DataInput in) |
void |
set(int fieldNum,
java.lang.Object val)
Set the value in a given field.
|
int |
size()
Find the size of the tuple.
|
void |
write(java.io.DataOutput out) |
equals, getType, isNull, iterator, reference, toDelimitedString, toStringpublic DefaultTuple()
public int size()
public java.lang.Object get(int fieldNum)
throws ExecException
fieldNum - Number of the field to get the value for.ExecException - if the field number is greater than or equal to the number of fields in the tuple.public java.util.List<java.lang.Object> getAll()
public void set(int fieldNum,
java.lang.Object val)
throws ExecException
fieldNum - Number of the field to set the value for.val - Object to put in the indicated field.ExecException - if the field number is greater than or equal to the number of fields in the tuple.public void append(java.lang.Object val)
val - Object to append to the tuple.public long getMemorySize()
public int compareTo(java.lang.Object other)
public int hashCode()
hashCode in class java.lang.Objectpublic void write(java.io.DataOutput out)
throws java.io.IOException
java.io.IOExceptionpublic void readFields(java.io.DataInput in)
throws java.io.IOException
java.io.IOExceptionpublic static java.lang.Class<? extends TupleRawComparator> getComparatorClass()
Copyright © 2007-2025 The Apache Software Foundation