@NotThreadSafe public class ScriptGraphStatementBuilder extends GraphStatementBuilderBase<ScriptGraphStatementBuilder,ScriptGraphStatement>
This class is mutable and not thread-safe.
consistencyLevel, executionProfile, executionProfileName, graphName, isIdempotent, node, readConsistencyLevel, subProtocol, timeout, timestamp, traversalSource, writeConsistencyLevel
Constructor and Description |
---|
ScriptGraphStatementBuilder() |
ScriptGraphStatementBuilder(ScriptGraphStatement template) |
ScriptGraphStatementBuilder(String script) |
Modifier and Type | Method and Description |
---|---|
ScriptGraphStatement |
build()
Create the statement with the configuration defined by this builder object.
|
ScriptGraphStatementBuilder |
clearQueryParams()
Clears all the parameters previously added to this builder.
|
ScriptGraphStatementBuilder |
removeQueryParam(String name)
Removes a parameter.
|
ScriptGraphStatementBuilder |
setQueryParam(String name,
Object value)
Set a value for a parameter defined in the script query.
|
ScriptGraphStatementBuilder |
setQueryParams(Map<String,Object> params)
Set multiple values for named parameters defined in the script query.
|
ScriptGraphStatementBuilder |
setScript(String script) |
ScriptGraphStatementBuilder |
setSystemQuery(Boolean isSystemQuery) |
addCustomPayload, buildCustomPayload, clearCustomPayload, setConsistencyLevel, setExecutionProfile, setExecutionProfileName, setGraphName, setIdempotence, setNode, setReadConsistencyLevel, setSubProtocol, setTimeout, setTimestamp, setTraversalSource, setWriteConsistencyLevel
public ScriptGraphStatementBuilder()
public ScriptGraphStatementBuilder(String script)
public ScriptGraphStatementBuilder(ScriptGraphStatement template)
@NonNull public ScriptGraphStatementBuilder setScript(@NonNull String script)
@NonNull public ScriptGraphStatementBuilder setSystemQuery(@Nullable Boolean isSystemQuery)
ScriptGraphStatement.isSystemQuery()
@NonNull public ScriptGraphStatementBuilder setQueryParam(@NonNull String name, @Nullable Object value)
@NonNull public ScriptGraphStatementBuilder setQueryParams(@NonNull Map<String,Object> params)
@NonNull public ScriptGraphStatementBuilder removeQueryParam(@NonNull String name)
This is useful if the builder was initialized with a template statement that has more parameters than desired.
public ScriptGraphStatementBuilder clearQueryParams()
@NonNull public ScriptGraphStatement build()
GraphStatementBuilderBase
build
in class GraphStatementBuilderBase<ScriptGraphStatementBuilder,ScriptGraphStatement>
Copyright © 2017–2024. All rights reserved.