当前位置: 首页>>代码示例>>Java>>正文


Java ExceptionFactory.edgeLabelCanNotBeNull方法代码示例

本文整理汇总了Java中com.tinkerpop.blueprints.util.ExceptionFactory.edgeLabelCanNotBeNull方法的典型用法代码示例。如果您正苦于以下问题:Java ExceptionFactory.edgeLabelCanNotBeNull方法的具体用法?Java ExceptionFactory.edgeLabelCanNotBeNull怎么用?Java ExceptionFactory.edgeLabelCanNotBeNull使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在com.tinkerpop.blueprints.util.ExceptionFactory的用法示例。


在下文中一共展示了ExceptionFactory.edgeLabelCanNotBeNull方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: addEdge

import com.tinkerpop.blueprints.util.ExceptionFactory; //导入方法依赖的package包/类
public CachedChronoEdge addEdge(final Long outVertexIdx, final Long inVertexIdx, final Long labelIdx) {
	if (labelIdx == null)
		throw ExceptionFactory.edgeLabelCanNotBeNull();

	CachedEdgeID edgeID = new CachedEdgeID(outVertexIdx, labelIdx, inVertexIdx);
	CachedChronoEdge edge = this.edges.get(edgeID);
	if (edge == null) {
		CachedChronoVertex out = getChronoVertex(outVertexIdx);
		CachedChronoVertex in = getChronoVertex(inVertexIdx);
		edge = new CachedChronoEdge(out, in, labelIdx, this);
		this.edges.put(edgeID, edge);
		out.addOutEdge(labelIdx, in);
		in.addInEdge(labelIdx, out);
	}
	return edge;
}
 
开发者ID:JaewookByun,项目名称:epcis,代码行数:17,代码来源:CachedChronoGraph.java

示例2: addEdge

import com.tinkerpop.blueprints.util.ExceptionFactory; //导入方法依赖的package包/类
/**
 * Add an edge as with {@link #addEdge(String, Vertex)},
 * but with a specified edge id.
 * @param id
 * @param label
 * @param inVertex
 * @return
 */
public Edge addEdge(Object id, String label, Vertex inVertex) {
  if (label == null) {
    throw ExceptionFactory.edgeLabelCanNotBeNull();
  }
  if (id == null) {
    id = AccumuloGraphUtils.generateId();
  }

  String myID = id.toString();

  AccumuloEdge edge = new AccumuloEdge(globals, myID, inVertex, this, label);

  // TODO we arent suppose to make sure the given edge ID doesn't already
  // exist?

  globals.getEdgeWrapper().writeEdge(edge);
  globals.getVertexWrapper().writeEdgeEndpoints(edge);

  globals.checkedFlush();

  globals.getCaches().cache(edge, Edge.class);

  return edge;
}
 
开发者ID:JHUAPL,项目名称:AccumuloGraph,代码行数:33,代码来源:AccumuloVertex.java

示例3: addEdge

import com.tinkerpop.blueprints.util.ExceptionFactory; //导入方法依赖的package包/类
@Override
public Edge addEdge(Object id, Vertex outVertex, Vertex inVertex, String label) {
    if (label == null)
        throw ExceptionFactory.edgeLabelCanNotBeNull();

    TitanikVertex titanikOutVertex = (TitanikVertex) outVertex;
    TitanikVertex titanikInVertex = (TitanikVertex) inVertex;

    TitanikEdge outEdge = titanikOutVertex.getOutEdge(label, titanikInVertex.getId());
    if (outEdge == null) {
        NewTitanikEdge edge = new NewTitanikEdge(this, titanikOutVertex, titanikInVertex, label);
        titanikOutVertex.addOutEdge(edge);
        titanikInVertex.addInEdge(edge);
        return edge;
    } else {
        return outEdge;
    }
}
 
开发者ID:dsiegel,项目名称:BlueprintsExperiment,代码行数:19,代码来源:TitanikTransactionalGraph.java

示例4: addEdge

import com.tinkerpop.blueprints.util.ExceptionFactory; //导入方法依赖的package包/类
@Override
public Edge addEdge(Object id, Vertex outVertex, Vertex inVertex, String label) {

	if (label == null) {
		throw ExceptionFactory.edgeLabelCanNotBeNull();
	}

	return ArangoDBEdge.create(this, id, outVertex, inVertex, label);
}
 
开发者ID:arangodb,项目名称:blueprints-arangodb-graph,代码行数:10,代码来源:ArangoDBGraph.java

示例5: addEdge

import com.tinkerpop.blueprints.util.ExceptionFactory; //导入方法依赖的package包/类
@Override
public Edge addEdge(String label, Vertex inVertex) {

	if (label == null) {
		throw ExceptionFactory.edgeLabelCanNotBeNull();
	}

	return ArangoDBEdge.create(this.graph, null, this, inVertex, label);
}
 
开发者ID:arangodb,项目名称:blueprints-arangodb-graph,代码行数:10,代码来源:ArangoDBVertex.java


注:本文中的com.tinkerpop.blueprints.util.ExceptionFactory.edgeLabelCanNotBeNull方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。