@InterfaceAudience.Public @InterfaceStability.Unstable public abstract class SchemaTuple<T extends SchemaTuple<T>> extends AbstractTuple implements TypeAwareTuple
Modifier and Type | Class and Description |
---|---|
static class |
SchemaTuple.SchemaTupleQuickGenerator<A> |
Constructor and Description |
---|
SchemaTuple() |
Modifier and Type | Method and Description |
---|---|
void |
append(Object val)
Append a field to a tuple.
|
protected BigDecimal |
box(BigDecimal v) |
protected BigInteger |
box(BigInteger v) |
protected Boolean |
box(boolean v) |
protected DataByteArray |
box(byte[] v) |
protected DataBag |
box(DataBag v) |
protected org.joda.time.DateTime |
box(org.joda.time.DateTime v) |
protected Double |
box(double v) |
protected Float |
box(float v) |
protected Integer |
box(int v) |
protected Long |
box(long v) |
protected Map<String,Object> |
box(Map<String,Object> v) |
protected String |
box(String v) |
protected Tuple |
box(Tuple t) |
protected int |
compare(BigDecimal val,
BigDecimal themVal) |
protected int |
compare(BigInteger val,
BigInteger themVal) |
protected int |
compare(boolean usNull,
BigDecimal usVal,
boolean themNull,
BigDecimal themVal) |
protected int |
compare(boolean usNull,
BigInteger usVal,
boolean themNull,
BigInteger themVal) |
protected int |
compare(boolean val,
boolean themVal) |
protected int |
compare(boolean usNull,
boolean usVal,
boolean themNull,
boolean themVal) |
protected int |
compare(boolean usNull,
byte[] usVal,
boolean themNull,
byte[] themVal) |
protected int |
compare(boolean usNull,
DataBag usVal,
boolean themNull,
DataBag themVal) |
protected int |
compare(boolean usNull,
org.joda.time.DateTime usVal,
boolean themNull,
org.joda.time.DateTime themVal) |
protected int |
compare(boolean usNull,
double usVal,
boolean themNull,
double themVal) |
protected int |
compare(boolean usNull,
float usVal,
boolean themNull,
float themVal) |
protected int |
compare(boolean usNull,
int usVal,
boolean themNull,
int themVal) |
protected int |
compare(boolean usNull,
long usVal,
boolean themNull,
long themVal) |
protected int |
compare(boolean usNull,
Map<String,Object> usVal,
boolean themNull,
Map<String,Object> themVal) |
protected int |
compare(boolean usNull,
SchemaTuple<?> usVal,
boolean themNull,
Object themVal) |
protected int |
compare(boolean usNull,
String usVal,
boolean themNull,
String themVal) |
protected int |
compare(byte[] val,
byte[] themVal) |
protected int |
compare(DataBag val,
DataBag themVal) |
protected int |
compare(org.joda.time.DateTime val,
org.joda.time.DateTime themVal) |
protected int |
compare(double val,
double themVal) |
int |
compare(float val,
float themVal) |
protected int |
compare(int val,
int themVal) |
protected int |
compare(long val,
long themVal) |
protected int |
compare(Map<String,Object> val,
Map<String,Object> themVal) |
protected int |
compare(String val,
String themVal) |
protected int |
compareElementAtPos(int val,
SchemaTuple<?> t,
int pos) |
protected int |
compareNull(boolean usNull,
boolean themNull) |
protected int |
compareNull(boolean usNull,
Tuple t,
int pos) |
protected int |
compareSize(Tuple t) |
int |
compareTo(Object other) |
int |
compareTo(SchemaTuple<?> t) |
protected int |
compareTo(SchemaTuple<?> t,
boolean checkType) |
int |
compareTo(Tuple t) |
protected int |
compareTo(Tuple t,
boolean checkType) |
protected int |
compareToSpecific(T t) |
protected int |
compareWithElementAtPos(boolean isNull,
BigDecimal val,
SchemaTuple<?> t,
int pos) |
protected int |
compareWithElementAtPos(boolean isNull,
BigInteger val,
SchemaTuple<?> t,
int pos) |
protected int |
compareWithElementAtPos(boolean isNull,
boolean val,
SchemaTuple<?> t,
int pos) |
protected int |
compareWithElementAtPos(boolean isNull,
byte[] val,
SchemaTuple<?> t,
int pos) |
protected int |
compareWithElementAtPos(boolean isNull,
DataBag val,
SchemaTuple<?> t,
int pos) |
protected int |
compareWithElementAtPos(boolean isNull,
org.joda.time.DateTime val,
SchemaTuple<?> t,
int pos) |
protected int |
compareWithElementAtPos(boolean isNull,
double val,
SchemaTuple<?> t,
int pos) |
protected int |
compareWithElementAtPos(boolean isNull,
float val,
SchemaTuple<?> t,
int pos) |
protected int |
compareWithElementAtPos(boolean isNull,
int val,
SchemaTuple<?> t,
int pos) |
protected int |
compareWithElementAtPos(boolean isNull,
long val,
SchemaTuple<?> t,
int pos) |
protected int |
compareWithElementAtPos(boolean isNull,
Map<String,Object> val,
SchemaTuple<?> t,
int pos) |
protected int |
compareWithElementAtPos(boolean isNull,
SchemaTuple<?> val,
SchemaTuple<?> t,
int pos) |
protected int |
compareWithElementAtPos(boolean isNull,
String val,
SchemaTuple<?> t,
int pos) |
boolean |
equals(Object other) |
protected abstract int |
generatedCodeCompareTo(SchemaTuple<?> t,
boolean checkType) |
protected abstract int |
generatedCodeCompareToSpecific(T t) |
protected abstract BigDecimal |
generatedCodeGetBigDecimal(int fieldNum) |
protected abstract BigInteger |
generatedCodeGetBigInteger(int fieldNum) |
protected abstract boolean |
generatedCodeGetBoolean(int fieldNum) |
protected abstract byte[] |
generatedCodeGetBytes(int fieldNum) |
protected abstract DataBag |
generatedCodeGetDataBag(int fieldNum) |
protected abstract org.joda.time.DateTime |
generatedCodeGetDateTime(int fieldNum) |
protected abstract double |
generatedCodeGetDouble(int fieldNum) |
abstract Object |
generatedCodeGetField(int fieldNum) |
protected abstract float |
generatedCodeGetFloat(int fieldNum) |
protected abstract int |
generatedCodeGetInt(int fieldNum) |
protected abstract long |
generatedCodeGetLong(int fieldNum) |
protected abstract Map<String,Object> |
generatedCodeGetMap(int fieldNum) |
protected abstract String |
generatedCodeGetString(int fieldNum) |
protected abstract Tuple |
generatedCodeGetTuple(int fieldNum) |
protected abstract int |
generatedCodeHashCode() |
protected abstract boolean[] |
generatedCodeNullsArray() |
protected abstract void |
generatedCodeReadFields(DataInput in,
boolean[] nulls) |
protected abstract SchemaTuple<T> |
generatedCodeSet(SchemaTuple<?> t,
boolean checkType) |
protected abstract void |
generatedCodeSetBigDecimal(int fieldNum,
BigDecimal val) |
protected abstract void |
generatedCodeSetBigInteger(int fieldNum,
BigInteger val) |
protected abstract void |
generatedCodeSetBoolean(int fieldNum,
boolean val) |
protected abstract void |
generatedCodeSetBytes(int fieldNum,
byte[] val) |
protected abstract void |
generatedCodeSetDataBag(int fieldNum,
DataBag val) |
protected abstract void |
generatedCodeSetDateTime(int fieldNum,
org.joda.time.DateTime val) |
protected abstract void |
generatedCodeSetDouble(int fieldNum,
double val) |
abstract void |
generatedCodeSetField(int fieldNum,
Object val) |
protected abstract void |
generatedCodeSetFloat(int fieldNum,
float val) |
protected abstract void |
generatedCodeSetInt(int fieldNum,
int val) |
protected abstract void |
generatedCodeSetIterator(Iterator<Object> l) |
protected abstract void |
generatedCodeSetLong(int fieldNum,
long val) |
protected abstract void |
generatedCodeSetMap(int fieldNum,
Map<String,Object> val) |
protected abstract SchemaTuple<T> |
generatedCodeSetSpecific(T t) |
protected abstract void |
generatedCodeSetString(int fieldNum,
String val) |
protected abstract void |
generatedCodeSetTuple(int fieldNum,
Tuple val) |
protected abstract int |
generatedCodeSize() |
protected abstract void |
generatedCodeWriteElements(DataOutput out) |
Object |
get(int fieldNum)
Get the value in a given field.
|
List<Object> |
getAll()
Get all of the fields in the tuple as a list.
|
BigDecimal |
getBigDecimal(int fieldNum) |
BigInteger |
getBigInteger(int fieldNum) |
boolean |
getBoolean(int fieldNum) |
byte[] |
getBytes(int fieldNum) |
DataBag |
getDataBag(int fieldNum) |
org.joda.time.DateTime |
getDateTime(int fieldNum) |
double |
getDouble(int fieldNum) |
float |
getFloat(int fieldNum) |
abstract byte |
getGeneratedCodeFieldType(int fieldNum) |
protected abstract long |
getGeneratedCodeMemorySize() |
int |
getInt(int fieldNum) |
long |
getLong(int fieldNum) |
Map<String,Object> |
getMap(int fieldNum) |
long |
getMemorySize()
This only accounts for the size of members (adjusting for word alignment).
|
abstract SchemaTuple.SchemaTupleQuickGenerator<T> |
getQuickGenerator()
This is a mechanism which allows the SchemaTupleFactory to
get around having to use reflection.
|
String |
getSchemaString() |
abstract int |
getSchemaTupleIdentifier()
This method will return the identifier that the generated code
was generated with.
|
String |
getString(int fieldNum) |
Tuple |
getTuple(int fieldNum) |
byte |
getType(int fieldNum)
Find the type of a given field.
|
protected Object |
getTypeAwareBase(int fieldNum,
String type) |
int |
hashCode() |
protected int |
hashCodePiece(int hash,
BigDecimal v,
boolean isNull) |
protected int |
hashCodePiece(int hash,
BigInteger v,
boolean isNull) |
protected int |
hashCodePiece(int hash,
boolean v,
boolean isNull) |
protected int |
hashCodePiece(int hash,
byte[] v,
boolean isNull) |
protected int |
hashCodePiece(int hash,
DataBag v,
boolean isNull) |
protected int |
hashCodePiece(int hash,
org.joda.time.DateTime v,
boolean isNull) |
protected int |
hashCodePiece(int hash,
double v,
boolean isNull) |
protected int |
hashCodePiece(int hash,
float v,
boolean isNull) |
protected int |
hashCodePiece(int hash,
int v,
boolean isNull) |
protected int |
hashCodePiece(int hash,
long v,
boolean isNull) |
protected int |
hashCodePiece(int hash,
Map<String,Object> v,
boolean isNull) |
protected int |
hashCodePiece(int hash,
String v,
boolean isNull) |
protected int |
hashCodePiece(int hash,
Tuple v,
boolean isNull) |
abstract boolean |
isGeneratedCodeFieldNull(int fieldNum) |
boolean |
isNull(int fieldNum)
Find out if a given field is null.
|
abstract boolean |
isSpecificSchemaTuple(Object o) |
protected static BigDecimal |
read(DataInput in,
BigDecimal v) |
protected static BigInteger |
read(DataInput in,
BigInteger v) |
protected static byte[] |
read(DataInput in,
byte[] v) |
protected static DataBag |
read(DataInput in,
DataBag v) |
protected static org.joda.time.DateTime |
read(DataInput in,
org.joda.time.DateTime v) |
protected static double |
read(DataInput in,
double v) |
protected static float |
read(DataInput in,
float v) |
protected static int |
read(DataInput in,
int v) |
protected static long |
read(DataInput in,
long v) |
protected static Map<String,Object> |
read(DataInput in,
Map<String,Object> v) |
protected static String |
read(DataInput in,
String v) |
void |
readFields(DataInput in) |
void |
reference(Tuple t)
Make this tuple reference the contents of another.
|
protected BigDecimal |
returnUnlessNull(boolean isNull,
BigDecimal val) |
protected BigInteger |
returnUnlessNull(boolean isNull,
BigInteger val) |
protected boolean |
returnUnlessNull(boolean isNull,
boolean val) |
protected byte[] |
returnUnlessNull(boolean isNull,
byte[] val) |
protected DataBag |
returnUnlessNull(boolean isNull,
DataBag val) |
protected org.joda.time.DateTime |
returnUnlessNull(boolean isNull,
org.joda.time.DateTime val) |
protected double |
returnUnlessNull(boolean isNull,
double val) |
protected float |
returnUnlessNull(boolean isNull,
float val) |
protected int |
returnUnlessNull(boolean isNull,
int val) |
protected long |
returnUnlessNull(boolean isNull,
long val) |
protected Map<String,Object> |
returnUnlessNull(boolean isNull,
Map<String,Object> val) |
protected String |
returnUnlessNull(boolean isNull,
String val) |
protected Tuple |
returnUnlessNull(boolean isNull,
Tuple val) |
protected abstract int |
schemaSize() |
void |
set(int fieldNum,
Object val)
Set the value in a given field.
|
SchemaTuple<T> |
set(List<Object> l) |
SchemaTuple<T> |
set(SchemaTuple<?> t) |
protected SchemaTuple<T> |
set(SchemaTuple<?> t,
boolean checkType) |
SchemaTuple<T> |
set(Tuple t) |
protected SchemaTuple<T> |
set(Tuple t,
boolean checkType) |
void |
setAndCatch(SchemaTuple<?> t) |
void |
setAndCatch(Tuple t) |
void |
setBigDecimal(int fieldNum,
BigDecimal val) |
void |
setBigInteger(int fieldNum,
BigInteger val) |
void |
setBoolean(int fieldNum,
boolean val) |
void |
setBytes(int fieldNum,
byte[] val) |
void |
setDataBag(int fieldNum,
DataBag val) |
void |
setDateTime(int fieldNum,
org.joda.time.DateTime val) |
void |
setDouble(int fieldNum,
double val) |
void |
setFloat(int fieldNum,
float val) |
void |
setInt(int fieldNum,
int val) |
void |
setLong(int fieldNum,
long val) |
void |
setMap(int fieldNum,
Map<String,Object> val) |
protected SchemaTuple<T> |
setSpecific(T t) |
void |
setString(int fieldNum,
String val) |
void |
setTuple(int fieldNum,
Tuple val) |
protected void |
setTypeAwareBase(int fieldNum,
Object val,
String type) |
int |
size()
Find the size of the tuple.
|
protected static Schema |
staticSchemaGen(String s) |
protected boolean |
unbox(Boolean v) |
protected DataBag |
unbox(DataBag v) |
protected byte[] |
unbox(DataByteArray v) |
protected org.joda.time.DateTime |
unbox(org.joda.time.DateTime v) |
protected double |
unbox(Double v) |
protected float |
unbox(Float v) |
protected int |
unbox(Integer v) |
protected long |
unbox(Long v) |
protected Map<String,Object> |
unbox(Map<String,Object> v) |
protected BigDecimal |
unbox(Object v,
BigDecimal t) |
protected BigInteger |
unbox(Object v,
BigInteger t) |
protected boolean |
unbox(Object v,
boolean t) |
protected byte[] |
unbox(Object v,
byte[] t) |
protected DataBag |
unbox(Object v,
DataBag t) |
protected org.joda.time.DateTime |
unbox(Object v,
org.joda.time.DateTime t) |
protected double |
unbox(Object v,
double t) |
protected float |
unbox(Object v,
float t) |
protected int |
unbox(Object v,
int t) |
protected long |
unbox(Object v,
long t) |
protected Map<String,Object> |
unbox(Object v,
Map<String,Object> t) |
protected String |
unbox(Object v,
String t) |
protected Tuple |
unbox(Object v,
Tuple t) |
BigDecimal |
unboxBigDecimal(Object val) |
BigInteger |
unboxBigInteger(Object val) |
boolean |
unboxBoolean(Object val) |
byte[] |
unboxBytes(Object val) |
protected DataBag |
unboxDataBag(Object val) |
org.joda.time.DateTime |
unboxDateTime(Object val) |
double |
unboxDouble(Object val) |
float |
unboxFloat(Object val) |
int |
unboxInt(Object val) |
long |
unboxLong(Object val) |
protected Map<String,Object> |
unboxMap(Object val) |
String |
unboxString(Object val) |
protected Tuple |
unboxTuple(Object val) |
void |
write(DataOutput out) |
protected static void |
write(DataOutput out,
BigDecimal v) |
protected static void |
write(DataOutput out,
BigInteger v) |
protected void |
write(DataOutput out,
boolean writeIdentifiers) |
protected static void |
write(DataOutput out,
byte[] v) |
protected static void |
write(DataOutput out,
DataBag v) |
protected static void |
write(DataOutput out,
org.joda.time.DateTime v) |
protected static void |
write(DataOutput out,
double v) |
protected static void |
write(DataOutput out,
float v) |
protected static void |
write(DataOutput out,
int v) |
protected static void |
write(DataOutput out,
long v) |
protected static void |
write(DataOutput out,
Map<String,Object> v) |
protected static void |
write(DataOutput out,
SchemaTuple<?> t) |
protected static void |
write(DataOutput out,
String v) |
protected void |
writeElements(DataOutput out)
This method is responsible for writing everything contained by the Tuple.
|
iterator, toDelimitedString, toString
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
getSchema
toDelimitedString
public void append(Object val)
Tuple
TupleFactory.newTuple(int)
and then fill in the values with
Tuple.set(int, Object)
, rather
than construct it with TupleFactory.newTuple()
and append values.public long getMemorySize()
getMemorySize
in interface Tuple
protected abstract long getGeneratedCodeMemorySize()
public abstract int getSchemaTupleIdentifier()
protected abstract int schemaSize()
public String getSchemaString()
protected SchemaTuple<T> set(SchemaTuple<?> t, boolean checkType) throws ExecException
ExecException
protected abstract SchemaTuple<T> generatedCodeSet(SchemaTuple<?> t, boolean checkType) throws ExecException
ExecException
protected SchemaTuple<T> setSpecific(T t)
protected abstract SchemaTuple<T> generatedCodeSetSpecific(T t)
public SchemaTuple<T> set(Tuple t) throws ExecException
ExecException
protected SchemaTuple<T> set(Tuple t, boolean checkType) throws ExecException
ExecException
public SchemaTuple<T> set(SchemaTuple<?> t) throws ExecException
ExecException
public SchemaTuple<T> set(List<Object> l) throws ExecException
ExecException
protected abstract void generatedCodeSetIterator(Iterator<Object> l) throws ExecException
ExecException
protected void write(DataOutput out, boolean writeIdentifiers) throws IOException
IOException
protected static void write(DataOutput out, DataBag v) throws IOException
IOException
protected static void write(DataOutput out, Map<String,Object> v) throws IOException
IOException
protected static void write(DataOutput out, int v) throws IOException
IOException
protected static void write(DataOutput out, long v) throws IOException
IOException
protected static void write(DataOutput out, float v) throws IOException
IOException
protected static void write(DataOutput out, double v) throws IOException
IOException
protected static void write(DataOutput out, org.joda.time.DateTime v) throws IOException
IOException
protected static void write(DataOutput out, BigDecimal v) throws IOException
IOException
protected static void write(DataOutput out, BigInteger v) throws IOException
IOException
protected static void write(DataOutput out, byte[] v) throws IOException
IOException
protected static void write(DataOutput out, String v) throws IOException
IOException
protected static void write(DataOutput out, SchemaTuple<?> t) throws IOException
IOException
protected static DataBag read(DataInput in, DataBag v) throws IOException
IOException
protected static Map<String,Object> read(DataInput in, Map<String,Object> v) throws IOException
IOException
protected static int read(DataInput in, int v) throws IOException
IOException
protected static long read(DataInput in, long v) throws IOException
IOException
protected static float read(DataInput in, float v) throws IOException
IOException
protected static double read(DataInput in, double v) throws IOException
IOException
protected static org.joda.time.DateTime read(DataInput in, org.joda.time.DateTime v) throws IOException
IOException
protected static BigDecimal read(DataInput in, BigDecimal v) throws IOException
IOException
protected static BigInteger read(DataInput in, BigInteger v) throws IOException
IOException
protected static String read(DataInput in, String v) throws IOException
IOException
protected static byte[] read(DataInput in, byte[] v) throws IOException
IOException
public void write(DataOutput out) throws IOException
write
in interface org.apache.hadoop.io.Writable
IOException
public void reference(Tuple t)
Tuple
reference
in interface Tuple
reference
in class AbstractTuple
t
- Tuple to reference.public List<Object> getAll()
Tuple
public abstract boolean isSpecificSchemaTuple(Object o)
public int compareTo(Object other)
compareTo
in interface Comparable
public int compareTo(Tuple t)
protected int compareTo(Tuple t, boolean checkType)
public int compareTo(SchemaTuple<?> t)
protected int compareTo(SchemaTuple<?> t, boolean checkType)
protected abstract int generatedCodeCompareTo(SchemaTuple<?> t, boolean checkType)
protected int compareToSpecific(T t)
protected abstract int generatedCodeCompareToSpecific(T t)
public boolean equals(Object other)
equals
in class AbstractTuple
protected byte[] unbox(Object v, byte[] t)
protected int unbox(Object v, int t)
protected long unbox(Object v, long t)
protected float unbox(Object v, float t)
protected double unbox(Object v, double t)
protected boolean unbox(Object v, boolean t)
protected org.joda.time.DateTime unbox(Object v, org.joda.time.DateTime t)
protected BigDecimal unbox(Object v, BigDecimal t)
protected BigInteger unbox(Object v, BigInteger t)
protected byte[] unbox(DataByteArray v)
protected int unbox(Integer v)
protected long unbox(Long v)
protected float unbox(Float v)
protected double unbox(Double v)
protected boolean unbox(Boolean v)
protected org.joda.time.DateTime unbox(org.joda.time.DateTime v)
protected DataByteArray box(byte[] v)
protected Integer box(int v)
protected Long box(long v)
protected Float box(float v)
protected Double box(double v)
protected Boolean box(boolean v)
protected org.joda.time.DateTime box(org.joda.time.DateTime v)
protected BigDecimal box(BigDecimal v)
protected BigInteger box(BigInteger v)
protected int hashCodePiece(int hash, int v, boolean isNull)
protected int hashCodePiece(int hash, long v, boolean isNull)
protected int hashCodePiece(int hash, float v, boolean isNull)
protected int hashCodePiece(int hash, double v, boolean isNull)
protected int hashCodePiece(int hash, boolean v, boolean isNull)
protected int hashCodePiece(int hash, org.joda.time.DateTime v, boolean isNull)
protected int hashCodePiece(int hash, BigDecimal v, boolean isNull)
protected int hashCodePiece(int hash, BigInteger v, boolean isNull)
protected int hashCodePiece(int hash, byte[] v, boolean isNull)
protected int hashCodePiece(int hash, String v, boolean isNull)
protected int hashCodePiece(int hash, Tuple v, boolean isNull)
protected int hashCodePiece(int hash, DataBag v, boolean isNull)
protected abstract int generatedCodeHashCode()
public void set(int fieldNum, Object val) throws ExecException
Tuple
TupleFactory.newTuple(int)
with an
argument greater than the fieldNum being passed here. This call will
not automatically expand the tuple size. That is if you called
TupleFactory.newTuple(int)
with a 2, it is okay to call
this function with a 1, but not with a 2 or greater.set
in interface Tuple
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 abstract void generatedCodeSetField(int fieldNum, Object val) throws ExecException
ExecException
public Object get(int fieldNum) throws ExecException
Tuple
get
in interface Tuple
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 abstract Object generatedCodeGetField(int fieldNum) throws ExecException
ExecException
public boolean isNull(int fieldNum) throws ExecException
AbstractTuple
isNull
in interface Tuple
isNull
in class AbstractTuple
fieldNum
- Number of field to check for null.ExecException
- if the field number given is greater
than or equal to the number of fields in the tuple.public abstract boolean isGeneratedCodeFieldNull(int fieldNum) throws ExecException
ExecException
public byte getType(int fieldNum) throws ExecException
AbstractTuple
getType
in interface Tuple
getType
in class AbstractTuple
fieldNum
- Number of field to get the type for.DataType
. If the field is null, then DataType.UNKNOWN
will be returned.ExecException
- if the field number is greater than or equal to
the number of fields in the tuple.public abstract byte getGeneratedCodeFieldType(int fieldNum) throws ExecException
ExecException
protected void setTypeAwareBase(int fieldNum, Object val, String type) throws ExecException
ExecException
protected Object getTypeAwareBase(int fieldNum, String type) throws ExecException
ExecException
public void setInt(int fieldNum, int val) throws ExecException
setInt
in interface TypeAwareTuple
ExecException
protected abstract void generatedCodeSetInt(int fieldNum, int val) throws ExecException
ExecException
public void setLong(int fieldNum, long val) throws ExecException
setLong
in interface TypeAwareTuple
ExecException
protected abstract void generatedCodeSetLong(int fieldNum, long val) throws ExecException
ExecException
public void setFloat(int fieldNum, float val) throws ExecException
setFloat
in interface TypeAwareTuple
ExecException
protected abstract void generatedCodeSetFloat(int fieldNum, float val) throws ExecException
ExecException
public void setDouble(int fieldNum, double val) throws ExecException
setDouble
in interface TypeAwareTuple
ExecException
protected abstract void generatedCodeSetDouble(int fieldNum, double val) throws ExecException
ExecException
public void setBoolean(int fieldNum, boolean val) throws ExecException
setBoolean
in interface TypeAwareTuple
ExecException
protected abstract void generatedCodeSetBoolean(int fieldNum, boolean val) throws ExecException
ExecException
public void setDateTime(int fieldNum, org.joda.time.DateTime val) throws ExecException
setDateTime
in interface TypeAwareTuple
ExecException
protected abstract void generatedCodeSetDateTime(int fieldNum, org.joda.time.DateTime val) throws ExecException
ExecException
public void setBigDecimal(int fieldNum, BigDecimal val) throws ExecException
setBigDecimal
in interface TypeAwareTuple
ExecException
protected abstract void generatedCodeSetBigDecimal(int fieldNum, BigDecimal val) throws ExecException
ExecException
public void setBigInteger(int fieldNum, BigInteger val) throws ExecException
setBigInteger
in interface TypeAwareTuple
ExecException
protected abstract void generatedCodeSetBigInteger(int fieldNum, BigInteger val) throws ExecException
ExecException
public void setString(int fieldNum, String val) throws ExecException
setString
in interface TypeAwareTuple
ExecException
protected abstract void generatedCodeSetString(int fieldNum, String val) throws ExecException
ExecException
public void setTuple(int fieldNum, Tuple val) throws ExecException
setTuple
in interface TypeAwareTuple
ExecException
protected abstract void generatedCodeSetTuple(int fieldNum, Tuple val) throws ExecException
ExecException
public void setBytes(int fieldNum, byte[] val) throws ExecException
setBytes
in interface TypeAwareTuple
ExecException
protected abstract void generatedCodeSetBytes(int fieldNum, byte[] val) throws ExecException
ExecException
public void setDataBag(int fieldNum, DataBag val) throws ExecException
setDataBag
in interface TypeAwareTuple
ExecException
protected abstract void generatedCodeSetDataBag(int fieldNum, DataBag val) throws ExecException
ExecException
public void setMap(int fieldNum, Map<String,Object> val) throws ExecException
setMap
in interface TypeAwareTuple
ExecException
protected abstract void generatedCodeSetMap(int fieldNum, Map<String,Object> val) throws ExecException
ExecException
protected int returnUnlessNull(boolean isNull, int val) throws FieldIsNullException
FieldIsNullException
protected long returnUnlessNull(boolean isNull, long val) throws FieldIsNullException
FieldIsNullException
protected float returnUnlessNull(boolean isNull, float val) throws FieldIsNullException
FieldIsNullException
protected double returnUnlessNull(boolean isNull, double val) throws FieldIsNullException
FieldIsNullException
protected boolean returnUnlessNull(boolean isNull, boolean val) throws FieldIsNullException
FieldIsNullException
protected org.joda.time.DateTime returnUnlessNull(boolean isNull, org.joda.time.DateTime val) throws FieldIsNullException
FieldIsNullException
protected BigDecimal returnUnlessNull(boolean isNull, BigDecimal val) throws FieldIsNullException
FieldIsNullException
protected BigInteger returnUnlessNull(boolean isNull, BigInteger val) throws FieldIsNullException
FieldIsNullException
protected Tuple returnUnlessNull(boolean isNull, Tuple val) throws FieldIsNullException
FieldIsNullException
protected String returnUnlessNull(boolean isNull, String val) throws FieldIsNullException
FieldIsNullException
protected byte[] returnUnlessNull(boolean isNull, byte[] val) throws FieldIsNullException
FieldIsNullException
protected DataBag returnUnlessNull(boolean isNull, DataBag val) throws FieldIsNullException
FieldIsNullException
protected Map<String,Object> returnUnlessNull(boolean isNull, Map<String,Object> val) throws FieldIsNullException
FieldIsNullException
public int getInt(int fieldNum) throws ExecException
getInt
in interface TypeAwareTuple
ExecException
protected abstract int generatedCodeGetInt(int fieldNum) throws ExecException
ExecException
public int unboxInt(Object val)
public long getLong(int fieldNum) throws ExecException
getLong
in interface TypeAwareTuple
ExecException
protected abstract long generatedCodeGetLong(int fieldNum) throws ExecException
ExecException
public long unboxLong(Object val)
public float getFloat(int fieldNum) throws ExecException
getFloat
in interface TypeAwareTuple
ExecException
protected abstract float generatedCodeGetFloat(int fieldNum) throws ExecException
ExecException
public float unboxFloat(Object val)
public double getDouble(int fieldNum) throws ExecException
getDouble
in interface TypeAwareTuple
ExecException
protected abstract double generatedCodeGetDouble(int fieldNum) throws ExecException
ExecException
public double unboxDouble(Object val)
public boolean getBoolean(int fieldNum) throws ExecException
getBoolean
in interface TypeAwareTuple
ExecException
protected abstract boolean generatedCodeGetBoolean(int fieldNum) throws ExecException
ExecException
public boolean unboxBoolean(Object val)
public org.joda.time.DateTime getDateTime(int fieldNum) throws ExecException
getDateTime
in interface TypeAwareTuple
ExecException
protected abstract org.joda.time.DateTime generatedCodeGetDateTime(int fieldNum) throws ExecException
ExecException
public org.joda.time.DateTime unboxDateTime(Object val)
public String getString(int fieldNum) throws ExecException
getString
in interface TypeAwareTuple
ExecException
protected abstract String generatedCodeGetString(int fieldNum) throws ExecException
ExecException
public byte[] getBytes(int fieldNum) throws ExecException
getBytes
in interface TypeAwareTuple
ExecException
public byte[] unboxBytes(Object val)
protected abstract byte[] generatedCodeGetBytes(int fieldNum) throws ExecException
ExecException
public Tuple getTuple(int fieldNum) throws ExecException
getTuple
in interface TypeAwareTuple
ExecException
protected abstract Tuple generatedCodeGetTuple(int fieldNum) throws ExecException
ExecException
public DataBag getDataBag(int fieldNum) throws ExecException
getDataBag
in interface TypeAwareTuple
ExecException
protected abstract DataBag generatedCodeGetDataBag(int fieldNum) throws ExecException
ExecException
public Map<String,Object> getMap(int fieldNum) throws ExecException
getMap
in interface TypeAwareTuple
ExecException
protected abstract Map<String,Object> generatedCodeGetMap(int fieldNum) throws ExecException
ExecException
public BigDecimal getBigDecimal(int fieldNum) throws ExecException
getBigDecimal
in interface TypeAwareTuple
ExecException
protected abstract BigDecimal generatedCodeGetBigDecimal(int fieldNum) throws ExecException
ExecException
public BigDecimal unboxBigDecimal(Object val)
public BigInteger getBigInteger(int fieldNum) throws ExecException
getBigInteger
in interface TypeAwareTuple
ExecException
protected abstract BigInteger generatedCodeGetBigInteger(int fieldNum) throws ExecException
ExecException
public BigInteger unboxBigInteger(Object val)
public void setAndCatch(Tuple t)
public void setAndCatch(SchemaTuple<?> t)
protected void writeElements(DataOutput out) throws IOException
out
- IOException
protected abstract void generatedCodeWriteElements(DataOutput out) throws IOException
IOException
protected int compareSize(Tuple t)
protected int compareNull(boolean usNull, boolean themNull)
protected int compareNull(boolean usNull, Tuple t, int pos)
protected int compareElementAtPos(int val, SchemaTuple<?> t, int pos)
protected int compare(boolean usNull, int usVal, boolean themNull, int themVal)
protected int compare(int val, int themVal)
protected int compareWithElementAtPos(boolean isNull, int val, SchemaTuple<?> t, int pos)
protected int compare(boolean usNull, long usVal, boolean themNull, long themVal)
protected int compare(long val, long themVal)
protected int compareWithElementAtPos(boolean isNull, long val, SchemaTuple<?> t, int pos)
protected int compare(boolean usNull, float usVal, boolean themNull, float themVal)
public int compare(float val, float themVal)
protected int compareWithElementAtPos(boolean isNull, float val, SchemaTuple<?> t, int pos)
protected int compare(boolean usNull, double usVal, boolean themNull, double themVal)
protected int compare(double val, double themVal)
protected int compareWithElementAtPos(boolean isNull, double val, SchemaTuple<?> t, int pos)
protected int compare(boolean usNull, boolean usVal, boolean themNull, boolean themVal)
protected int compare(boolean val, boolean themVal)
protected int compareWithElementAtPos(boolean isNull, boolean val, SchemaTuple<?> t, int pos)
protected int compare(boolean usNull, byte[] usVal, boolean themNull, byte[] themVal)
protected int compare(byte[] val, byte[] themVal)
protected int compareWithElementAtPos(boolean isNull, byte[] val, SchemaTuple<?> t, int pos)
protected int compare(boolean usNull, org.joda.time.DateTime usVal, boolean themNull, org.joda.time.DateTime themVal)
protected int compare(org.joda.time.DateTime val, org.joda.time.DateTime themVal)
protected int compareWithElementAtPos(boolean isNull, org.joda.time.DateTime val, SchemaTuple<?> t, int pos)
protected int compare(boolean usNull, BigDecimal usVal, boolean themNull, BigDecimal themVal)
protected int compare(BigDecimal val, BigDecimal themVal)
protected int compareWithElementAtPos(boolean isNull, BigDecimal val, SchemaTuple<?> t, int pos)
protected int compare(boolean usNull, BigInteger usVal, boolean themNull, BigInteger themVal)
protected int compare(BigInteger val, BigInteger themVal)
protected int compareWithElementAtPos(boolean isNull, BigInteger val, SchemaTuple<?> t, int pos)
protected int compareWithElementAtPos(boolean isNull, String val, SchemaTuple<?> t, int pos)
protected int compareWithElementAtPos(boolean isNull, DataBag val, SchemaTuple<?> t, int pos)
protected int compare(boolean usNull, Map<String,Object> usVal, boolean themNull, Map<String,Object> themVal)
protected int compareWithElementAtPos(boolean isNull, Map<String,Object> val, SchemaTuple<?> t, int pos)
protected int compareWithElementAtPos(boolean isNull, SchemaTuple<?> val, SchemaTuple<?> t, int pos)
protected int compare(boolean usNull, SchemaTuple<?> usVal, boolean themNull, Object themVal)
public abstract SchemaTuple.SchemaTupleQuickGenerator<T> getQuickGenerator()
public int size()
Tuple
protected abstract int generatedCodeSize()
public void readFields(DataInput in) throws IOException
readFields
in interface org.apache.hadoop.io.Writable
IOException
protected abstract void generatedCodeReadFields(DataInput in, boolean[] nulls) throws IOException
IOException
protected abstract boolean[] generatedCodeNullsArray() throws IOException
IOException
Copyright © 2007-2012 The Apache Software Foundation