public static class DriverDSL.DefaultImpls
Underlying interface for the driver DSL. Do not instantiate directly, instead use the Driver.driver
function.
Driver.driver
Modifier and Type | Method and Description |
---|---|
static NotaryHandle |
getDefaultNotaryHandle(DriverDSL $this)
Returns the
class NotaryHandle for the single notary on the network. Throws if there are none or more than one. |
static Party |
getDefaultNotaryIdentity(DriverDSL $this)
Returns the identity of the single notary on the network. Throws if there are none or more than one.
|
static CordaFuture<net.corda.testing.driver.NodeHandle> |
getDefaultNotaryNode(DriverDSL $this)
Returns a
interface CordaFuture on the interface NodeHandle for the single-node notary on the network. Throws if there
are no notaries or more than one, or if the notary is a distributed cluster. |
static int |
nextPort(DriverDSL $this)
Returns the next port to use when instantiating test processes that must not conflict on the same machine
|
static CordaFuture<net.corda.testing.driver.NodeHandle> |
startNode(DriverDSL $this)
Start a node using the default values of
class NodeParameters . |
static CordaFuture<net.corda.testing.driver.NodeHandle> |
startNode(DriverDSL $this,
NodeParameters defaultParameters,
CordaX500Name providedName,
java.util.List<net.corda.testing.node.User> rpcUsers,
VerifierType verifierType,
java.util.Map<java.lang.String,? extends java.lang.Object> customOverrides,
java.lang.Boolean startInSameProcess,
java.lang.String maximumHeapSize,
java.lang.String logLevelOverride)
Start a node.
|
static CordaFuture<net.corda.testing.driver.NodeHandle> |
startNode(DriverDSL $this,
NodeParameters defaultParameters,
CordaX500Name providedName,
java.util.List<net.corda.testing.node.User> rpcUsers,
VerifierType verifierType,
java.util.Map<java.lang.String,? extends java.lang.Object> customOverrides,
java.lang.Boolean startInSameProcess,
java.lang.String maximumHeapSize)
Start a node.
|
static CordaFuture<net.corda.testing.driver.WebserverHandle> |
startWebserver(DriverDSL $this,
NodeHandle handle)
Call
DriverDSL.startWebserver with a default maximumHeapSize. |
public static NotaryHandle getDefaultNotaryHandle(DriverDSL $this)
Returns the class NotaryHandle
for the single notary on the network. Throws if there are none or more than one.
class NotaryHandle
,
DriverDSL.getNotaryHandles
public static Party getDefaultNotaryIdentity(DriverDSL $this)
Returns the identity of the single notary on the network. Throws if there are none or more than one.
DriverDSL.getDefaultNotaryHandle
public static CordaFuture<net.corda.testing.driver.NodeHandle> getDefaultNotaryNode(DriverDSL $this)
Returns a interface CordaFuture
on the interface NodeHandle
for the single-node notary on the network. Throws if there
are no notaries or more than one, or if the notary is a distributed cluster.
public static CordaFuture<net.corda.testing.driver.NodeHandle> startNode(DriverDSL $this)
Start a node using the default values of class NodeParameters
.
interface CordaFuture
on the interface NodeHandle
to the node. The future will complete when the node is available and
it sees all previously started nodes, including the notaries.class NodeParameters
public static CordaFuture<net.corda.testing.driver.NodeHandle> startNode(DriverDSL $this, NodeParameters defaultParameters, CordaX500Name providedName, java.util.List<net.corda.testing.node.User> rpcUsers, VerifierType verifierType, java.util.Map<java.lang.String,? extends java.lang.Object> customOverrides, java.lang.Boolean startInSameProcess, java.lang.String maximumHeapSize, java.lang.String logLevelOverride)
Start a node.
NOTE: This method does not provide all the node parameters that are available and only exists for backwards compatibility. It is
recommended you use class NodeParameters
.
defaultParameters
- The default parameters for the node. If any of the remaining parameters to this method are specified then
their values are taken instead of the corresponding value in defaultParameters.providedName
- Optional name of the node, which will be its legal name in class Party
. Defaults to something
random. Note that this must be unique as the driver uses it as a primary key!rpcUsers
- List of users who are authorised to use the RPC system. Defaults to empty list.verifierType
- The type of transaction verifier to use. See: enum VerifierType
.customOverrides
- A map of custom node configuration overrides.startInSameProcess
- Determines if the node should be started inside the same process the Driver is running
in. If null the Driver-level value will be used.maximumHeapSize
- The maximum JVM heap size to use for the node as a String. By default a number is interpreted
as being in bytes. Append the letter 'k' or 'K' to the value to indicate Kilobytes, 'm' or 'M' to indicate
megabytes, and 'g' or 'G' to indicate gigabytes. The default value is "512m" = 512 megabytes.logLevelOverride
- log4j log level used to override the default value of info.interface CordaFuture
on the interface NodeHandle
to the node. The future will complete when the node is available and
it sees all previously started nodes, including the notaries.class NodeParameters
public static CordaFuture<net.corda.testing.driver.NodeHandle> startNode(DriverDSL $this, NodeParameters defaultParameters, CordaX500Name providedName, java.util.List<net.corda.testing.node.User> rpcUsers, VerifierType verifierType, java.util.Map<java.lang.String,? extends java.lang.Object> customOverrides, java.lang.Boolean startInSameProcess, java.lang.String maximumHeapSize)
Start a node.
NOTE: This method does not provide all the node parameters that are available and only exists for backwards compatibility. It is
recommended you use class NodeParameters
.
defaultParameters
- The default parameters for the node. If any of the remaining parameters to this method are specified then
their values are taken instead of the corresponding value in defaultParameters.providedName
- Optional name of the node, which will be its legal name in class Party
. Defaults to something
random. Note that this must be unique as the driver uses it as a primary key!rpcUsers
- List of users who are authorised to use the RPC system. Defaults to empty list.verifierType
- The type of transaction verifier to use. See: enum VerifierType
.customOverrides
- A map of custom node configuration overrides.startInSameProcess
- Determines if the node should be started inside the same process the Driver is running
in. If null the Driver-level value will be used.maximumHeapSize
- The maximum JVM heap size to use for the node as a String. By default a number is interpreted
as being in bytes. Append the letter 'k' or 'K' to the value to indicate Kilobytes, 'm' or 'M' to indicate
megabytes, and 'g' or 'G' to indicate gigabytes. The default value is "512m" = 512 megabytes.interface CordaFuture
on the interface NodeHandle
to the node. The future will complete when the node is available and
it sees all previously started nodes, including the notaries.class NodeParameters
public static CordaFuture<net.corda.testing.driver.WebserverHandle> startWebserver(DriverDSL $this, NodeHandle handle)
Call DriverDSL.startWebserver
with a default maximumHeapSize.
DriverDSL.startWebserver
public static int nextPort(DriverDSL $this)
Returns the next port to use when instantiating test processes that must not conflict on the same machine