Class AnonymousTraversalSource<T extends TraversalSource>
- java.lang.Object
-
- org.apache.tinkerpop.gremlin.process.traversal.AnonymousTraversalSource<T>
-
public class AnonymousTraversalSource<T extends TraversalSource> extends Object
Provides a unified way to construct aTraversalSource
from the perspective of the traversal. In this syntax the user is creating the source and binding it to a reference which is either an existingGraph
instance or aRemoteConnection
.- Author:
- Stephen Mallette (http://stephen.genoprime.com)
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static AnonymousTraversalSource<GraphTraversalSource>
traversal()
Constructs anAnonymousTraversalSource
which will then be configured to spawn aGraphTraversalSource
.static <T extends TraversalSource>
AnonymousTraversalSource<T>traversal(Class<T> traversalSourceClass)
Constructs anAnonymousTraversalSource
which will then be configured to spawn the specifiedTraversalSource
.T
with(String configFile)
Creates aTraversalSource
from a configuration file which may either be for aGraph
instance or for aRemoteConnection
.T
with(org.apache.commons.configuration2.Configuration conf)
Creates aTraversalSource
from a configuration object which may either be for aGraph
instance or for aRemoteConnection
.T
with(org.apache.tinkerpop.gremlin.process.remote.RemoteConnection remoteConnection)
Creates aTraversalSource
binding aRemoteConnection
to a remoteGraph
instances as its reference so that traversals spawned from it will execute over that reference.T
with(Graph graph)
Creates the specifiedTraversalSource
binding an embeddedGraph
as its reference such that traversals spawned from it will execute over that reference.T
withEmbedded(Graph graph)
Deprecated.As of release 4.0.0, replaced bywith(Graph)
T
withRemote(String configFile)
Deprecated.As of release 4.0.0, replaced bywith(String)
T
withRemote(org.apache.commons.configuration2.Configuration conf)
Deprecated.As of release 4.0.0, replaced bywith(Configuration)
T
withRemote(org.apache.tinkerpop.gremlin.process.remote.RemoteConnection remoteConnection)
Deprecated.As of release 4.0.0, replaced bywith(RemoteConnection)
-
-
-
Method Detail
-
traversal
public static AnonymousTraversalSource<GraphTraversalSource> traversal()
Constructs anAnonymousTraversalSource
which will then be configured to spawn aGraphTraversalSource
.
-
traversal
public static <T extends TraversalSource> AnonymousTraversalSource<T> traversal(Class<T> traversalSourceClass)
Constructs anAnonymousTraversalSource
which will then be configured to spawn the specifiedTraversalSource
.
-
withRemote
@Deprecated public T withRemote(String configFile) throws Exception
Deprecated.As of release 4.0.0, replaced bywith(String)
Creates aTraversalSource
binding aRemoteConnection
to a remoteGraph
instances as its reference so that traversals spawned from it will execute over that reference.- Parameters:
configFile
- a path to a file that would normally be provided to configure aRemoteConnection
- Throws:
Exception
-
withRemote
@Deprecated public T withRemote(org.apache.commons.configuration2.Configuration conf)
Deprecated.As of release 4.0.0, replaced bywith(Configuration)
Creates aTraversalSource
binding aRemoteConnection
to a remoteGraph
instances as its reference so that traversals spawned from it will execute over that reference.- Parameters:
conf
- aConfiguration
object that would normally be provided to configure aRemoteConnection
-
withRemote
@Deprecated public T withRemote(org.apache.tinkerpop.gremlin.process.remote.RemoteConnection remoteConnection)
Deprecated.As of release 4.0.0, replaced bywith(RemoteConnection)
Creates aTraversalSource
binding aRemoteConnection
to a remoteGraph
instances as its reference so that traversals spawned from it will execute over that reference.
-
withEmbedded
@Deprecated public T withEmbedded(Graph graph)
Deprecated.As of release 4.0.0, replaced bywith(Graph)
Creates the specifiedTraversalSource
binding an embeddedGraph
as its reference such that traversals spawned from it will execute over that reference.
-
with
public T with(Graph graph)
Creates the specifiedTraversalSource
binding an embeddedGraph
as its reference such that traversals spawned from it will execute over that reference.
-
with
public T with(org.apache.tinkerpop.gremlin.process.remote.RemoteConnection remoteConnection)
Creates aTraversalSource
binding aRemoteConnection
to a remoteGraph
instances as its reference so that traversals spawned from it will execute over that reference.
-
with
public T with(String configFile) throws Exception
Creates aTraversalSource
from a configuration file which may either be for aGraph
instance or for aRemoteConnection
.- Parameters:
configFile
- a path to a configuration file- Throws:
Exception
-
with
public T with(org.apache.commons.configuration2.Configuration conf)
Creates aTraversalSource
from a configuration object which may either be for aGraph
instance or for aRemoteConnection
.- Parameters:
conf
- aConfiguration
object that would normally be provided to configure aRemoteConnection
-
-