public final class TokenRelation extends Relation
relationType| Constructor and Description |
|---|
TokenRelation(java.util.List<ColumnIdentifier.Raw> entities,
Operator type,
Term.Raw value) |
| Modifier and Type | Method and Description |
|---|---|
protected Restriction |
newContainsRestriction(CFMetaData cfm,
VariableSpecifications boundNames,
boolean isKey)
Creates a new Contains restriction instance.
|
protected Restriction |
newEQRestriction(CFMetaData cfm,
VariableSpecifications boundNames)
Creates a new EQ restriction instance.
|
protected Restriction |
newINRestriction(CFMetaData cfm,
VariableSpecifications boundNames)
Creates a new IN restriction instance.
|
protected Restriction |
newSliceRestriction(CFMetaData cfm,
VariableSpecifications boundNames,
Bound bound,
boolean inclusive)
Creates a new Slice restriction instance.
|
boolean |
onToken()
Checks if this relation is a token relation (e.g.
|
java.lang.String |
toString() |
protected Term |
toTerm(java.util.List<? extends ColumnSpecification> receivers,
Term.Raw raw,
java.lang.String keyspace,
VariableSpecifications boundNames)
Converts the specified
Raw into a Term. |
isContains, isContainsKey, isEQ, isIN, isMultiColumn, isSlice, operator, toColumnDefinition, toRestriction, toTermspublic TokenRelation(java.util.List<ColumnIdentifier.Raw> entities, Operator type, Term.Raw value)
public boolean onToken()
Relationtoken(a) = token(1)).
protected Restriction newEQRestriction(CFMetaData cfm, VariableSpecifications boundNames) throws InvalidRequestException
RelationnewEQRestriction in class Relationcfm - the Column Family meta databoundNames - the variables specification where to collect the bind variablesInvalidRequestException - if the relation cannot be converted into an EQ restriction.protected Restriction newINRestriction(CFMetaData cfm, VariableSpecifications boundNames) throws InvalidRequestException
RelationnewINRestriction in class Relationcfm - the Column Family meta databoundNames - the variables specification where to collect the bind variablesInvalidRequestException - if the relation cannot be converted into an IN restriction.protected Restriction newSliceRestriction(CFMetaData cfm, VariableSpecifications boundNames, Bound bound, boolean inclusive) throws InvalidRequestException
RelationnewSliceRestriction in class Relationcfm - the Column Family meta databoundNames - the variables specification where to collect the bind variablesbound - the slice boundinclusive - true if the bound is included.InvalidRequestException - if the Relation is not validprotected Restriction newContainsRestriction(CFMetaData cfm, VariableSpecifications boundNames, boolean isKey) throws InvalidRequestException
RelationnewContainsRestriction in class Relationcfm - the Column Family meta databoundNames - the variables specification where to collect the bind variablesisKey - true if the restriction to create is a CONTAINS KEYRestriction instanceInvalidRequestException - if the Relation is not validprotected Term toTerm(java.util.List<? extends ColumnSpecification> receivers, Term.Raw raw, java.lang.String keyspace, VariableSpecifications boundNames) throws InvalidRequestException
RelationRaw into a Term.toTerm in class Relationreceivers - the columns to which the values must be associated atraw - the raw term to convertkeyspace - the keyspace nameboundNames - the variables specification where to collect the bind variablesTerm corresponding to the specified RawInvalidRequestException - if the Raw term is not validpublic java.lang.String toString()
toString in class java.lang.ObjectCopyright © 2015 The Apache Software Foundation