本文整理汇总了Java中org.apache.cassandra.cql3.Relation类的典型用法代码示例。如果您正苦于以下问题:Java Relation类的具体用法?Java Relation怎么用?Java Relation使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
Relation类属于org.apache.cassandra.cql3包,在下文中一共展示了Relation类的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: add
import org.apache.cassandra.cql3.Relation; //导入依赖的package包/类
public Builder add(ByteBuffer buffer, Relation.Type op)
{
if (components.size() >= composite.types.size())
throw new IllegalStateException("Composite column is already fully constructed");
int current = components.size();
components.add(buffer);
/*
* Given the rules for eoc (end-of-component, see AbstractCompositeType.compare()),
* We can select:
* - = 'a' by using <'a'><0>
* - < 'a' by using <'a'><-1>
* - <= 'a' by using <'a'><1>
* - > 'a' by using <'a'><1>
* - >= 'a' by using <'a'><0>
*/
switch (op)
{
case LT:
endOfComponents[current] = (byte) -1;
break;
case GT:
case LTE:
endOfComponents[current] = (byte) 1;
break;
default:
endOfComponents[current] = (byte) 0;
break;
}
return this;
}
开发者ID:pgaref,项目名称:ACaZoo,代码行数:33,代码来源:CompositeType.java
示例2: UnrecognizedEntityException
import org.apache.cassandra.cql3.Relation; //导入依赖的package包/类
/**
* Creates a new <code>UnrecognizedEntityException</code>.
* @param entity the unrecognized entity
* @param relation the entity relation
*/
public UnrecognizedEntityException(ColumnIdentifier entity, Relation relation)
{
super(String.format("Undefined name %s in where clause ('%s')", entity, relation));
this.entity = entity;
this.relation = relation;
}
开发者ID:scylladb,项目名称:scylla-tools-java,代码行数:12,代码来源:UnrecognizedEntityException.java
示例3: buildForRelation
import org.apache.cassandra.cql3.Relation; //导入依赖的package包/类
public ByteBuffer buildForRelation(Relation.Type op)
{
/*
* Given the rules for eoc (end-of-component, see AbstractCompositeType.compare()),
* We can select:
* - = 'a' by using <'a'><0>
* - < 'a' by using <'a'><-1>
* - <= 'a' by using <'a'><1>
* - > 'a' by using <'a'><1>
* - >= 'a' by using <'a'><0>
*/
int current = components.size() - 1;
switch (op)
{
case LT:
endOfComponents[current] = (byte) -1;
break;
case GT:
case LTE:
endOfComponents[current] = (byte) 1;
break;
default:
endOfComponents[current] = (byte) 0;
break;
}
return build();
}
开发者ID:daidong,项目名称:GraphTrek,代码行数:28,代码来源:CompositeType.java
示例4: EdgeSelector
import org.apache.cassandra.cql3.Relation; //导入依赖的package包/类
public EdgeSelector(){
this.edgeWhere = new ArrayList<Relation>();
this.endWhere = new ArrayList<Relation>();
}
开发者ID:daidong,项目名称:GraphTrek,代码行数:5,代码来源:EdgeSelector.java
示例5: setEdgeWhere
import org.apache.cassandra.cql3.Relation; //导入依赖的package包/类
public void setEdgeWhere(List<Relation> edgeWhere){
this.edgeWhere = edgeWhere;
}
开发者ID:daidong,项目名称:GraphTrek,代码行数:4,代码来源:EdgeSelector.java
示例6: setEndWhere
import org.apache.cassandra.cql3.Relation; //导入依赖的package包/类
public void setEndWhere(List<Relation> endWhere){
this.endWhere = endWhere;
}
开发者ID:daidong,项目名称:GraphTrek,代码行数:4,代码来源:EdgeSelector.java
示例7: getEdgeWhere
import org.apache.cassandra.cql3.Relation; //导入依赖的package包/类
public List<Relation> getEdgeWhere(){
return this.edgeWhere;
}
开发者ID:daidong,项目名称:GraphTrek,代码行数:4,代码来源:EdgeSelector.java
示例8: getEndWhere
import org.apache.cassandra.cql3.Relation; //导入依赖的package包/类
public List<Relation> getEndWhere(){
return this.endWhere;
}
开发者ID:daidong,项目名称:GraphTrek,代码行数:4,代码来源:EdgeSelector.java
注:本文中的org.apache.cassandra.cql3.Relation类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论