VID - the vertex ID typepublic class GraphBuilderImpl<VID> extends oracle.pgx.api.internal.ApiObject implements GraphBuilder<VID>
PgxGraph.| Modifier and Type | Method and Description |
|---|---|
EdgeBuilder<VID> |
addEdge(long edgeId, VertexBuilder<VID> srcVertex, VertexBuilder<VID> dstVertex)
Adds an edge with the given edge ID and the given source and destination vertices.
|
EdgeBuilder<VID> |
addEdge(long edgeId, VID srcVertex, VID dstVertex)
Adds an edge with the given edge ID and the given source and destination vertices.
|
VertexBuilder<VID> |
addVertex(VID vertexId)
Adds the vertex with the given id to the graph builder.
|
PgxGraph |
build()
Blocking version of
GraphBuilder.buildAsync(). |
PgxGraph |
build(java.lang.String newGraphName)
Blocking version of
GraphBuilder.buildAsync(String). |
PgxFuture<PgxGraph> |
buildAsync()
Shortcut for
GraphBuilder.buildAsync(String) without a name |
PgxFuture<PgxGraph> |
buildAsync(java.lang.String newGraphName)
Builds a new graph out of the changes in this graph builder
|
java.lang.Object |
getConfigParameter(GraphBuilderConfig.Field parameter)
Retrieve the value for the given config parameter
|
PgxSession |
getSession()
Gets the session.
|
GraphBuilder<VID> |
resetEdge(long edgeId)
Resets any change for the edge with the given ID.
|
GraphBuilder<VID> |
resetVertex(VertexBuilder<VID> vertex)
Resets any change for the given vertex.
|
GraphBuilder<VID> |
resetVertex(VID vertexId)
Resets any change for the vertex with the given ID.
|
void |
setConfigParameter(GraphBuilderConfig.Field parameter, java.lang.Object value)
Set the given configuration parameter to the given value
|
java.lang.String |
toString() |
equals, getClass, hashCode, notify, notifyAll, wait, wait, waitsetRetainEdgeIds, setRetainIds, setRetainVertexIdspublic EdgeBuilder<VID> addEdge(long edgeId, VertexBuilder<VID> srcVertex, VertexBuilder<VID> dstVertex)
GraphBuilderaddEdge in interface GraphBuilder<VID>edgeId - the ID of the new edgesrcVertex - a VertexBuilderImpl instance representing the source vertexdstVertex - a VertexBuilderImpl instance representing the destination vertexVertexBuilderImplpublic EdgeBuilder<VID> addEdge(long edgeId, VID srcVertex, VID dstVertex)
GraphBuilderaddEdge in interface GraphBuilder<VID>edgeId - the ID of the new edgesrcVertex - the source ID of the new edgedstVertex - the destination ID of the new edgepublic VertexBuilder<VID> addVertex(VID vertexId)
GraphBuilderaddVertex in interface GraphBuilder<VID>vertexId - the ID of the new vertexpublic final PgxGraph build() throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
GraphBuilderGraphBuilder.buildAsync(). Calls GraphBuilder.buildAsync() and waits for the returned PgxFuture to complete.build in interface GraphBuilder<VID>java.util.concurrent.ExecutionException - if any exception occurred during asynchronous execution. The actual exception will be nested.java.lang.InterruptedException - if the caller thread gets interrupted while waiting for completion.public final PgxGraph build(java.lang.String newGraphName) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
GraphBuilderGraphBuilder.buildAsync(String). Calls GraphBuilder.buildAsync(String) and waits for the returned PgxFuture to complete.build in interface GraphBuilder<VID>java.util.concurrent.ExecutionException - if any exception occurred during asynchronous execution. The actual exception will be nested.java.lang.InterruptedException - if the caller thread gets interrupted while waiting for completion.public final PgxFuture<PgxGraph> buildAsync()
GraphBuilderGraphBuilder.buildAsync(String) without a namebuildAsync in interface GraphBuilder<VID>public final PgxFuture<PgxGraph> buildAsync(java.lang.String newGraphName)
GraphBuilderbuildAsync in interface GraphBuilder<VID>newGraphName - the new name of the graph. If null a name is generatedpublic java.lang.Object getConfigParameter(GraphBuilderConfig.Field parameter)
GraphBuildergetConfigParameter in interface GraphBuilder<VID>parameter - the config parameter to get the value forpublic final PgxSession getSession()
public GraphBuilder<VID> resetEdge(long edgeId)
GraphBuilderresetEdge in interface GraphBuilder<VID>edgeId - the ID of the edge which should be resetpublic GraphBuilder<VID> resetVertex(VertexBuilder<VID> vertex)
GraphBuilderresetVertex in interface GraphBuilder<VID>vertex - a VertexBuilderpublic GraphBuilder<VID> resetVertex(VID vertexId)
GraphBuilderresetVertex in interface GraphBuilder<VID>vertexId - the ID of the vertex which should be resetpublic void setConfigParameter(GraphBuilderConfig.Field parameter, java.lang.Object value)
GraphBuildersetConfigParameter in interface GraphBuilder<VID>parameter - the config parameter to setvalue - the new value for the config parameterpublic java.lang.String toString()
toString in class java.lang.ObjectCopyright © 2016, 2018 Oracle and/or its affiliates. All Rights Reserved.