public class TransactionHandle extends Object implements TransactionTerminationHandle
TransactionHandle does not immediately ask the kernel to create a
KernelTransaction; instead a KernelTransaction is
only created when the first statements need to be executed.
At the end of each statement-executing method, the KernelTransaction is either
suspended (ready to be resumed by a later operation), or committed, or rolled back.
If you acquire instances of this class from TransactionHandleRegistry, it will prevent concurrent access to
the same instance. Therefore the implementation assumes that a single instance will only be accessed from
a single thread.
All of the public methods on this class are "single-shot"; once you have called one method, the handle returns
itself
to the registry. If you want to use it again, you'll need to acquire it back from the registry to ensure exclusive
use.| Modifier and Type | Method and Description |
|---|---|
void |
commit(StatementDeserializer statements,
ExecutionResultSerializer output,
javax.servlet.http.HttpServletRequest request) |
void |
execute(StatementDeserializer statements,
ExecutionResultSerializer output,
javax.servlet.http.HttpServletRequest request) |
boolean |
isImplicit() |
void |
rollback(ExecutionResultSerializer output) |
boolean |
terminate() |
URI |
uri() |
public URI uri()
public boolean isImplicit()
public void execute(StatementDeserializer statements, ExecutionResultSerializer output, javax.servlet.http.HttpServletRequest request)
public boolean terminate()
terminate in interface TransactionTerminationHandlepublic void commit(StatementDeserializer statements, ExecutionResultSerializer output, javax.servlet.http.HttpServletRequest request)
public void rollback(ExecutionResultSerializer output)
Copyright © 2002–2018 The Neo4j Graph Database Project. All rights reserved.