org.apache.blur.thrift.generated
Class ColumnDefinition

java.lang.Object
  extended by org.apache.blur.thrift.generated.ColumnDefinition
All Implemented Interfaces:
Serializable, Cloneable, Comparable<ColumnDefinition>, TBase<ColumnDefinition,ColumnDefinition._Fields>

public class ColumnDefinition
extends Object
implements TBase<ColumnDefinition,ColumnDefinition._Fields>, Serializable, Cloneable

The ColumnDefinition defines how a given Column should be interpreted (indexed/stored)

See Also:
Serialized Form

Nested Class Summary
static class ColumnDefinition._Fields
          The set of fields this struct contains, along with convenience methods for finding and manipulating them.
 
Field Summary
 String columnName
          Required.
 String family
          Required.
 boolean fieldLessIndexed
          If this column should be searchable without having to specify the name of the column in the query.
 String fieldType
          The field type for the column.
static Map<ColumnDefinition._Fields,FieldMetaData> metaDataMap
           
 Map<String,String> properties
          For any custom field types, you can pass in configuration properties.
 boolean sortable
          This will attempt to enable sorting for this column, if the type does not support sorting then an exception will be thrown.
 String subColumnName
          If this column definition is for a sub column then provide the sub column name.
 
Constructor Summary
ColumnDefinition()
           
ColumnDefinition(ColumnDefinition other)
          Performs a deep copy on other.
ColumnDefinition(String family, String columnName, String subColumnName, boolean fieldLessIndexed, String fieldType, Map<String,String> properties, boolean sortable)
           
 
Method Summary
 void clear()
          Return to the state of having just been initialized, as though you had just called the default constructor.
 int compareTo(ColumnDefinition other)
           
 ColumnDefinition deepCopy()
           
 boolean equals(ColumnDefinition that)
           
 boolean equals(Object that)
           
 ColumnDefinition._Fields fieldForId(int fieldId)
          Get the F instance that corresponds to fieldId.
 String getColumnName()
          Required.
 String getFamily()
          Required.
 String getFieldType()
          The field type for the column.
 Object getFieldValue(ColumnDefinition._Fields field)
          Get a field's value by field variable.
 Map<String,String> getProperties()
          For any custom field types, you can pass in configuration properties.
 int getPropertiesSize()
           
 String getSubColumnName()
          If this column definition is for a sub column then provide the sub column name.
 int hashCode()
           
 boolean isFieldLessIndexed()
          If this column should be searchable without having to specify the name of the column in the query.
 boolean isSet(ColumnDefinition._Fields field)
          Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise
 boolean isSetColumnName()
          Returns true if field columnName is set (has been assigned a value) and false otherwise
 boolean isSetFamily()
          Returns true if field family is set (has been assigned a value) and false otherwise
 boolean isSetFieldLessIndexed()
          Returns true if field fieldLessIndexed is set (has been assigned a value) and false otherwise
 boolean isSetFieldType()
          Returns true if field fieldType is set (has been assigned a value) and false otherwise
 boolean isSetProperties()
          Returns true if field properties is set (has been assigned a value) and false otherwise
 boolean isSetSortable()
          Returns true if field sortable is set (has been assigned a value) and false otherwise
 boolean isSetSubColumnName()
          Returns true if field subColumnName is set (has been assigned a value) and false otherwise
 boolean isSortable()
          This will attempt to enable sorting for this column, if the type does not support sorting then an exception will be thrown.
 void putToProperties(String key, String val)
           
 void read(TProtocol iprot)
          Reads the TObject from the given input protocol.
 ColumnDefinition setColumnName(String columnName)
          Required.
 void setColumnNameIsSet(boolean value)
           
 ColumnDefinition setFamily(String family)
          Required.
 void setFamilyIsSet(boolean value)
           
 ColumnDefinition setFieldLessIndexed(boolean fieldLessIndexed)
          If this column should be searchable without having to specify the name of the column in the query.
 void setFieldLessIndexedIsSet(boolean value)
           
 ColumnDefinition setFieldType(String fieldType)
          The field type for the column.
 void setFieldTypeIsSet(boolean value)
           
 void setFieldValue(ColumnDefinition._Fields field, Object value)
          Set a field's value by field variable.
 ColumnDefinition setProperties(Map<String,String> properties)
          For any custom field types, you can pass in configuration properties.
 void setPropertiesIsSet(boolean value)
           
 ColumnDefinition setSortable(boolean sortable)
          This will attempt to enable sorting for this column, if the type does not support sorting then an exception will be thrown.
 void setSortableIsSet(boolean value)
           
 ColumnDefinition setSubColumnName(String subColumnName)
          If this column definition is for a sub column then provide the sub column name.
 void setSubColumnNameIsSet(boolean value)
           
 String toString()
           
 void unsetColumnName()
           
 void unsetFamily()
           
 void unsetFieldLessIndexed()
           
 void unsetFieldType()
           
 void unsetProperties()
           
 void unsetSortable()
           
 void unsetSubColumnName()
           
 void validate()
           
 void write(TProtocol oprot)
          Writes the objects out to the protocol
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

family

public String family
Required. The family that this column exists within.


columnName

public String columnName
Required. The column name.


subColumnName

public String subColumnName
If this column definition is for a sub column then provide the sub column name. Otherwise leave this field null.


fieldLessIndexed

public boolean fieldLessIndexed
If this column should be searchable without having to specify the name of the column in the query. NOTE: This will index the column as a full text field in a default field, so that means it's going to be indexed twice.


fieldType

public String fieldType
The field type for the column. The built in types are:


properties

public Map<String,String> properties
For any custom field types, you can pass in configuration properties.


sortable

public boolean sortable
This will attempt to enable sorting for this column, if the type does not support sorting then an exception will be thrown.


metaDataMap

public static final Map<ColumnDefinition._Fields,FieldMetaData> metaDataMap
Constructor Detail

ColumnDefinition

public ColumnDefinition()

ColumnDefinition

public ColumnDefinition(String family,
                        String columnName,
                        String subColumnName,
                        boolean fieldLessIndexed,
                        String fieldType,
                        Map<String,String> properties,
                        boolean sortable)

ColumnDefinition

public ColumnDefinition(ColumnDefinition other)
Performs a deep copy on other.

Method Detail

deepCopy

public ColumnDefinition deepCopy()
Specified by:
deepCopy in interface TBase<ColumnDefinition,ColumnDefinition._Fields>

clear

public void clear()
Description copied from interface: TBase
Return to the state of having just been initialized, as though you had just called the default constructor.

Specified by:
clear in interface TBase<ColumnDefinition,ColumnDefinition._Fields>

getFamily

public String getFamily()
Required. The family that this column exists within.


setFamily

public ColumnDefinition setFamily(String family)
Required. The family that this column exists within.


unsetFamily

public void unsetFamily()

isSetFamily

public boolean isSetFamily()
Returns true if field family is set (has been assigned a value) and false otherwise


setFamilyIsSet

public void setFamilyIsSet(boolean value)

getColumnName

public String getColumnName()
Required. The column name.


setColumnName

public ColumnDefinition setColumnName(String columnName)
Required. The column name.


unsetColumnName

public void unsetColumnName()

isSetColumnName

public boolean isSetColumnName()
Returns true if field columnName is set (has been assigned a value) and false otherwise


setColumnNameIsSet

public void setColumnNameIsSet(boolean value)

getSubColumnName

public String getSubColumnName()
If this column definition is for a sub column then provide the sub column name. Otherwise leave this field null.


setSubColumnName

public ColumnDefinition setSubColumnName(String subColumnName)
If this column definition is for a sub column then provide the sub column name. Otherwise leave this field null.


unsetSubColumnName

public void unsetSubColumnName()

isSetSubColumnName

public boolean isSetSubColumnName()
Returns true if field subColumnName is set (has been assigned a value) and false otherwise


setSubColumnNameIsSet

public void setSubColumnNameIsSet(boolean value)

isFieldLessIndexed

public boolean isFieldLessIndexed()
If this column should be searchable without having to specify the name of the column in the query. NOTE: This will index the column as a full text field in a default field, so that means it's going to be indexed twice.


setFieldLessIndexed

public ColumnDefinition setFieldLessIndexed(boolean fieldLessIndexed)
If this column should be searchable without having to specify the name of the column in the query. NOTE: This will index the column as a full text field in a default field, so that means it's going to be indexed twice.


unsetFieldLessIndexed

public void unsetFieldLessIndexed()

isSetFieldLessIndexed

public boolean isSetFieldLessIndexed()
Returns true if field fieldLessIndexed is set (has been assigned a value) and false otherwise


setFieldLessIndexedIsSet

public void setFieldLessIndexedIsSet(boolean value)

getFieldType

public String getFieldType()
The field type for the column. The built in types are:


setFieldType

public ColumnDefinition setFieldType(String fieldType)
The field type for the column. The built in types are:


unsetFieldType

public void unsetFieldType()

isSetFieldType

public boolean isSetFieldType()
Returns true if field fieldType is set (has been assigned a value) and false otherwise


setFieldTypeIsSet

public void setFieldTypeIsSet(boolean value)

getPropertiesSize

public int getPropertiesSize()

putToProperties

public void putToProperties(String key,
                            String val)

getProperties

public Map<String,String> getProperties()
For any custom field types, you can pass in configuration properties.


setProperties

public ColumnDefinition setProperties(Map<String,String> properties)
For any custom field types, you can pass in configuration properties.


unsetProperties

public void unsetProperties()

isSetProperties

public boolean isSetProperties()
Returns true if field properties is set (has been assigned a value) and false otherwise


setPropertiesIsSet

public void setPropertiesIsSet(boolean value)

isSortable

public boolean isSortable()
This will attempt to enable sorting for this column, if the type does not support sorting then an exception will be thrown.


setSortable

public ColumnDefinition setSortable(boolean sortable)
This will attempt to enable sorting for this column, if the type does not support sorting then an exception will be thrown.


unsetSortable

public void unsetSortable()

isSetSortable

public boolean isSetSortable()
Returns true if field sortable is set (has been assigned a value) and false otherwise


setSortableIsSet

public void setSortableIsSet(boolean value)

setFieldValue

public void setFieldValue(ColumnDefinition._Fields field,
                          Object value)
Description copied from interface: TBase
Set a field's value by field variable. Primitive types must be "boxed" in the appropriate object wrapper type.

Specified by:
setFieldValue in interface TBase<ColumnDefinition,ColumnDefinition._Fields>

getFieldValue

public Object getFieldValue(ColumnDefinition._Fields field)
Description copied from interface: TBase
Get a field's value by field variable. Primitive types will be wrapped in the appropriate "boxed" types.

Specified by:
getFieldValue in interface TBase<ColumnDefinition,ColumnDefinition._Fields>

isSet

public boolean isSet(ColumnDefinition._Fields field)
Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise

Specified by:
isSet in interface TBase<ColumnDefinition,ColumnDefinition._Fields>

equals

public boolean equals(Object that)
Overrides:
equals in class Object

equals

public boolean equals(ColumnDefinition that)

hashCode

public int hashCode()
Overrides:
hashCode in class Object

compareTo

public int compareTo(ColumnDefinition other)
Specified by:
compareTo in interface Comparable<ColumnDefinition>

fieldForId

public ColumnDefinition._Fields fieldForId(int fieldId)
Description copied from interface: TBase
Get the F instance that corresponds to fieldId.

Specified by:
fieldForId in interface TBase<ColumnDefinition,ColumnDefinition._Fields>

read

public void read(TProtocol iprot)
          throws TException
Description copied from interface: TBase
Reads the TObject from the given input protocol.

Specified by:
read in interface TBase<ColumnDefinition,ColumnDefinition._Fields>
Parameters:
iprot - Input protocol
Throws:
TException

write

public void write(TProtocol oprot)
           throws TException
Description copied from interface: TBase
Writes the objects out to the protocol

Specified by:
write in interface TBase<ColumnDefinition,ColumnDefinition._Fields>
Parameters:
oprot - Output protocol
Throws:
TException

toString

public String toString()
Overrides:
toString in class Object

validate

public void validate()
              throws TException
Throws:
TException


Copyright © 2012-2014 The Apache Software Foundation. All Rights Reserved.