com.netflix.astyanax.model
Class AbstractColumnImpl<C>

java.lang.Object
  extended by com.netflix.astyanax.model.AbstractColumnImpl<C>
All Implemented Interfaces:
Column<C>
Direct Known Subclasses:
EmptyColumn

public abstract class AbstractColumnImpl<C>
extends java.lang.Object
implements Column<C>


Constructor Summary
AbstractColumnImpl(C name)
           
 
Method Summary
 boolean getBooleanValue()
          Get value as a boolean
 byte[] getByteArrayValue()
          Get the raw byte[] value
 java.nio.ByteBuffer getByteBufferValue()
          Get the raw ByteBuffer value
 byte getByteValue()
          Return value as an integer
 java.lang.String getCompressedStringValue()
          Return a string that was stored as a compressed blob
 java.util.Date getDateValue()
          Get the value as a date object
 double getDoubleValue()
          Return value as a double
 float getFloatValue()
          Return value as a float
 int getIntegerValue()
          Return value as an integer
 long getLongValue()
          Return value as a long.
 C getName()
          Column or super column name
 short getShortValue()
          Return value as an integer
 java.lang.String getStringValue()
          Return value as a string
<C2> ColumnList<C2>
getSubColumns(Serializer<C2> ser)
          Get columns in the case of a super column.
 java.util.UUID getUUIDValue()
          Get the value as a UUID
 boolean isParentColumn()
          Returns true if the column contains a list of child columns, otherwise the column contains a value.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.netflix.astyanax.model.Column
getRawName, getTimestamp, getTtl, getValue, hasValue
 

Constructor Detail

AbstractColumnImpl

public AbstractColumnImpl(C name)
Method Detail

getName

public final C getName()
Description copied from interface: Column
Column or super column name

Specified by:
getName in interface Column<C>
Returns:

getStringValue

public final java.lang.String getStringValue()
Description copied from interface: Column
Return value as a string

Specified by:
getStringValue in interface Column<C>
Returns:

getByteValue

public final byte getByteValue()
Description copied from interface: Column
Return value as an integer

Specified by:
getByteValue in interface Column<C>
Returns:

getShortValue

public final short getShortValue()
Description copied from interface: Column
Return value as an integer

Specified by:
getShortValue in interface Column<C>
Returns:

getIntegerValue

public final int getIntegerValue()
Description copied from interface: Column
Return value as an integer

Specified by:
getIntegerValue in interface Column<C>
Returns:

getLongValue

public long getLongValue()
Description copied from interface: Column
Return value as a long. Use this to get the value of a counter column

Specified by:
getLongValue in interface Column<C>
Returns:

getByteArrayValue

public final byte[] getByteArrayValue()
Description copied from interface: Column
Get the raw byte[] value

Specified by:
getByteArrayValue in interface Column<C>
Returns:

getBooleanValue

public final boolean getBooleanValue()
Description copied from interface: Column
Get value as a boolean

Specified by:
getBooleanValue in interface Column<C>
Returns:

getByteBufferValue

public final java.nio.ByteBuffer getByteBufferValue()
Description copied from interface: Column
Get the raw ByteBuffer value

Specified by:
getByteBufferValue in interface Column<C>
Returns:

getDateValue

public final java.util.Date getDateValue()
Description copied from interface: Column
Get the value as a date object

Specified by:
getDateValue in interface Column<C>
Returns:

getUUIDValue

public final java.util.UUID getUUIDValue()
Description copied from interface: Column
Get the value as a UUID

Specified by:
getUUIDValue in interface Column<C>
Returns:

getFloatValue

public final float getFloatValue()
Description copied from interface: Column
Return value as a float

Specified by:
getFloatValue in interface Column<C>
Returns:

getDoubleValue

public final double getDoubleValue()
Description copied from interface: Column
Return value as a double

Specified by:
getDoubleValue in interface Column<C>
Returns:

getCompressedStringValue

public final java.lang.String getCompressedStringValue()
Description copied from interface: Column
Return a string that was stored as a compressed blob

Specified by:
getCompressedStringValue in interface Column<C>
Returns:

getSubColumns

public <C2> ColumnList<C2> getSubColumns(Serializer<C2> ser)
Description copied from interface: Column
Get columns in the case of a super column. Will throw an exception if this is a regular column Valid only if isCompositeColumn returns true

Specified by:
getSubColumns in interface Column<C>
Type Parameters:
C2 - Type of column names for sub columns
Returns:

isParentColumn

public boolean isParentColumn()
Description copied from interface: Column
Returns true if the column contains a list of child columns, otherwise the column contains a value.

Specified by:
isParentColumn in interface Column<C>
Returns: