org.apache.cassandra.cql3

## Class Relation

- java.lang.Object
- - org.apache.cassandra.cql3.Relation

    public class Relation
    extends java.lang.Object

Relations encapsulate the relationship between an entity of some kind, and a value (term). For example, <key> > "start" or "colname1" = "somevalue".

### Nested Class Summary

Nested Classes
`static class` `Relation.Type`

### Field Summary

Fields
`boolean` `onToken`
`ColumnIdentifier` `previousInTuple`

### Constructor Summary

Constructors
Constructor and Description
`Relation(ColumnIdentifier entity, Relation.Type type, Term.Raw value)` Creates a new relation.
`Relation(ColumnIdentifier entity, Relation.Type type, Term.Raw value, boolean onToken)`
`Relation(ColumnIdentifier entity, Relation.Type type, Term.Raw value, ColumnIdentifier previousInTuple)`

### Method Summary

Methods
`void` `addInValue(Term.Raw t)`
`static Relation` `createInRelation(ColumnIdentifier entity)`
`ColumnIdentifier` `getEntity()`
`java.util.List<Term.Raw>` `getInValues()`
`Term.Raw` `getValue()`
`Relation.Type` `operator()`
`java.lang.String` `toString()`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

### Field Detail

#### onToken

    public final boolean onToken

#### previousInTuple

    public final ColumnIdentifier previousInTuple

### Constructor Detail

#### Relation

    public Relation(ColumnIdentifier entity,
            Relation.Type type,
            Term.Raw value)

Creates a new relation.

Parameters:
  `entity` - the kind of relation this is; what the term is being compared to.
  `type` - the type that describes how this entity relates to the value.
  `value` - the value being compared.

#### Relation

    public Relation(ColumnIdentifier entity,
            Relation.Type type,
            Term.Raw value,
            boolean onToken)

#### Relation

    public Relation(ColumnIdentifier entity,
            Relation.Type type,
            Term.Raw value,
            ColumnIdentifier previousInTuple)

### Method Detail

#### createInRelation

    public static Relation createInRelation(ColumnIdentifier entity)

#### operator

    public Relation.Type operator()

#### getEntity

    public ColumnIdentifier getEntity()

#### getValue

    public Term.Raw getValue()

#### getInValues

    public java.util.List<Term.Raw> getInValues()

#### addInValue

    public void addInValue(Term.Raw t)

#### toString

    public java.lang.String toString()

Overrides:
  `toString` in class `java.lang.Object`