NodeParameters
Keywords: net.corda.testing.driver.NodeParameters class
Date: 2023-09-18

net.corda.testing.driver

## Class NodeParameters

- net.corda.testing.driver.NodeParameters

-     public class NodeParameters

  Parameters for creating a node for `DriverDSL.startNode`.

  See Also:
    `DriverDSL.startNode`

- - ### Constructor Detail

    - #### NodeParameters

          public NodeParameters(@Nullable
                                CordaX500Name providedName,
                                @NotNull
                                java.util.List<net.corda.testing.node.User> rpcUsers,
                                @NotNull
                                VerifierType verifierType,
                                @NotNull
                                java.util.Map<java.lang.String,? extends java.lang.Object> customOverrides,
                                @Nullable
                                java.lang.Boolean startInSameProcess,
                                @NotNull
                                java.lang.String maximumHeapSize,
                                @NotNull
                                java.util.Collection<? extends net.corda.testing.node.TestCordapp> additionalCordapps,
                                @NotNull
                                java.util.Map<? extends java.lang.Class<? extends net.corda.core.flows.FlowLogic<?>>,? extends java.lang.Class<? extends net.corda.core.flows.FlowLogic<?>>> flowOverrides,
                                @Nullable
                                java.lang.String logLevelOverride,
                                @Nullable
                                NetworkHostAndPort rpcAddress)

      Parameters for creating a node for `DriverDSL.startNode`.

      Parameters:
        `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 a single user with all permissions.
        `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. Defaults to 512 MB.
        `additionalCordapps` - Additional `class TestCordapp`s that this node will have available, in addition to the ones common to all nodesmanaged by the `interface DriverDSL`.
        `logLevelOverride` - log level to be passed as parameter to an out of process node. ERROR, WARN, INFO, DEBUG, TRACE. This overrides debug portlog level argument.
        `rpcAddress` - optional override for RPC address on which node will be accepting RPC connections from the clients. Port provided must be vacant.
      See Also:
        `DriverDSL.startNode`

    - #### NodeParameters

          public NodeParameters()

      Create a new node parameters object with default values. Each parameter can be specified with its wither method which returns a copy with that value.

    - #### NodeParameters

          public NodeParameters(@Nullable
                                CordaX500Name providedName,
                                @NotNull
                                java.util.List<net.corda.testing.node.User> rpcUsers,
                                @NotNull
                                VerifierType verifierType,
                                @NotNull
                                java.util.Map<java.lang.String,? extends java.lang.Object> customOverrides,
                                @Nullable
                                java.lang.Boolean startInSameProcess,
                                @NotNull
                                java.lang.String maximumHeapSize)

    - #### NodeParameters

          public NodeParameters(@Nullable
                                CordaX500Name providedName,
                                @NotNull
                                java.util.List<net.corda.testing.node.User> rpcUsers,
                                @NotNull
                                VerifierType verifierType,
                                @NotNull
                                java.util.Map<java.lang.String,? extends java.lang.Object> customOverrides,
                                @Nullable
                                java.lang.Boolean startInSameProcess,
                                @NotNull
                                java.lang.String maximumHeapSize,
                                @NotNull
                                java.util.Collection<? extends net.corda.testing.node.TestCordapp> additionalCordapps,
                                @NotNull
                                java.util.Map<? extends java.lang.Class<? extends net.corda.core.flows.FlowLogic<?>>,? extends java.lang.Class<? extends net.corda.core.flows.FlowLogic<?>>> flowOverrides)

  - ### Method Detail

    - #### withProvidedName

          @NotNull
          public NodeParameters withProvidedName(@Nullable
                                                          CordaX500Name providedName)

    - #### withRpcUsers

          @NotNull
          public NodeParameters withRpcUsers(@NotNull
                                                      java.util.List<net.corda.testing.node.User> rpcUsers)

    - #### withVerifierType

          @NotNull
          public NodeParameters withVerifierType(@NotNull
                                                          VerifierType verifierType)

    - #### withCustomOverrides

          @NotNull
          public NodeParameters withCustomOverrides(@NotNull
                                                             java.util.Map<java.lang.String,? extends java.lang.Object> customOverrides)

    - #### withStartInSameProcess

          @NotNull
          public NodeParameters withStartInSameProcess(@Nullable
                                                                java.lang.Boolean startInSameProcess)

    - #### withMaximumHeapSize

          @NotNull
          public NodeParameters withMaximumHeapSize(@NotNull
                                                             java.lang.String maximumHeapSize)

    - #### withAdditionalCordapps

          @NotNull
          public NodeParameters withAdditionalCordapps(@NotNull
                                                                java.util.Set<? extends net.corda.testing.node.TestCordapp> additionalCordapps)

    - #### withFlowOverrides

          @NotNull
          public NodeParameters withFlowOverrides(@NotNull
                                                           java.util.Map<java.lang.Class,? extends java.lang.Class<? extends net.corda.core.flows.FlowLogic<?>>> flowOverrides)

    - #### withLogLevelOverride

          @NotNull
          public NodeParameters withLogLevelOverride(@Nullable
                                                              java.lang.String logLevelOverride)

    - #### copy

          @NotNull
          public NodeParameters copy(@Nullable
                                              CordaX500Name providedName,
                                              @NotNull
                                              java.util.List<net.corda.testing.node.User> rpcUsers,
                                              @NotNull
                                              VerifierType verifierType,
                                              @NotNull
                                              java.util.Map<java.lang.String,? extends java.lang.Object> customOverrides,
                                              @Nullable
                                              java.lang.Boolean startInSameProcess,
                                              @NotNull
                                              java.lang.String maximumHeapSize)

    - #### copy

          @NotNull
          public NodeParameters copy(@Nullable
                                              CordaX500Name providedName,
                                              @NotNull
                                              java.util.List<net.corda.testing.node.User> rpcUsers,
                                              @NotNull
                                              VerifierType verifierType,
                                              @NotNull
                                              java.util.Map<java.lang.String,? extends java.lang.Object> customOverrides,
                                              @Nullable
                                              java.lang.Boolean startInSameProcess,
                                              @NotNull
                                              java.lang.String maximumHeapSize,
                                              @NotNull
                                              java.util.Collection<? extends net.corda.testing.node.TestCordapp> additionalCordapps,
                                              @NotNull
                                              java.util.Map<? extends java.lang.Class<? extends net.corda.core.flows.FlowLogic<?>>,? extends java.lang.Class<? extends net.corda.core.flows.FlowLogic<?>>> flowOverrides)

    - #### getProvidedName

          @Nullable
          public CordaX500Name getProvidedName()

      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!

      See Also:
        `class Party`

    - #### getRpcUsers

          @NotNull
          public java.util.List<net.corda.testing.node.User> getRpcUsers()

      List of users who are authorised to use the RPC system.

      Defaults to a single user with all permissions.

    - #### getVerifierType

          @NotNull
          public VerifierType getVerifierType()

      The type of transaction verifier to use.

      See: `enum VerifierType`

      See Also:
        `enum VerifierType`

    - #### getCustomOverrides

          @NotNull
          public java.util.Map<java.lang.String,java.lang.Object> getCustomOverrides()

      A map of custom node configuration overrides.

    - #### getStartInSameProcess

          @Nullable
          public java.lang.Boolean getStartInSameProcess()

      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.

    - #### getMaximumHeapSize

          @NotNull
          public java.lang.String getMaximumHeapSize()

      The maximum JVM heap size to use for the node.

      Defaults to 512 MB.

    - #### getAdditionalCordapps

          @NotNull
          public java.util.Collection<net.corda.testing.node.TestCordapp> getAdditionalCordapps()

      Additional

      `class TestCordapp`s that this node will have available, in addition to the ones common to all nodesmanaged by the `interface DriverDSL`.

      See Also:
        `class TestCordapp`, `interface DriverDSL`

    - #### getFlowOverrides

          @NotNull
          public java.util.Map<? extends java.lang.Class<? extends net.corda.core.flows.FlowLogic<?>>,java.lang.Class> getFlowOverrides()

    - #### getLogLevelOverride

          @Nullable
          public java.lang.String getLogLevelOverride()

      log level to be passed as parameter to an out of process node.

      ERROR, WARN, INFO, DEBUG, TRACE. This overrides debug portlog level argument.

    - #### getRpcAddress

          @Nullable
          public NetworkHostAndPort getRpcAddress()

      optional override for RPC address on which node will be accepting RPC connections from the clients.

      Port provided must be vacant.

    - #### component1

          @Nullable
          public CordaX500Name component1()

      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!

      See Also:
        `class Party`

    - #### component2

          @NotNull
          public java.util.List<net.corda.testing.node.User> component2()

      List of users who are authorised to use the RPC system.

      Defaults to a single user with all permissions.

    - #### component3

          @NotNull
          public VerifierType component3()

      The type of transaction verifier to use.

      See: `enum VerifierType`

      See Also:
        `enum VerifierType`

    - #### component4

          @NotNull
          public java.util.Map<java.lang.String,java.lang.Object> component4()

      A map of custom node configuration overrides.

    - #### component5

          @Nullable
          public java.lang.Boolean component5()

      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.

    - #### component6

          @NotNull
          public java.lang.String component6()

      The maximum JVM heap size to use for the node.

      Defaults to 512 MB.

    - #### component7

          @NotNull
          public java.util.Collection<net.corda.testing.node.TestCordapp> component7()

      Additional

      `class TestCordapp`s that this node will have available, in addition to the ones common to all nodesmanaged by the `interface DriverDSL`.

      See Also:
        `class TestCordapp`, `interface DriverDSL`

    - #### component8

          @NotNull
          public java.util.Map<? extends java.lang.Class<? extends net.corda.core.flows.FlowLogic<?>>,java.lang.Class> component8()

    - #### component9

          @Nullable
          public java.lang.String component9()

      log level to be passed as parameter to an out of process node.

      ERROR, WARN, INFO, DEBUG, TRACE. This overrides debug portlog level argument.

    - #### component10

          @Nullable
          public NetworkHostAndPort component10()

      optional override for RPC address on which node will be accepting RPC connections from the clients.

      Port provided must be vacant.

    - #### copy

          @NotNull
          public NodeParameters copy(@Nullable
                                              CordaX500Name providedName,
                                              @NotNull
                                              java.util.List<net.corda.testing.node.User> rpcUsers,
                                              @NotNull
                                              VerifierType verifierType,
                                              @NotNull
                                              java.util.Map<java.lang.String,? extends java.lang.Object> customOverrides,
                                              @Nullable
                                              java.lang.Boolean startInSameProcess,
                                              @NotNull
                                              java.lang.String maximumHeapSize,
                                              @NotNull
                                              java.util.Collection<? extends net.corda.testing.node.TestCordapp> additionalCordapps,
                                              @NotNull
                                              java.util.Map<? extends java.lang.Class<? extends net.corda.core.flows.FlowLogic<?>>,? extends java.lang.Class<? extends net.corda.core.flows.FlowLogic<?>>> flowOverrides,
                                              @Nullable
                                              java.lang.String logLevelOverride,
                                              @Nullable
                                              NetworkHostAndPort rpcAddress)

      Parameters for creating a node for `DriverDSL.startNode`.

      See Also:
        `DriverDSL.startNode`

    - #### toString

          @NotNull
          public java.lang.String toString()

      Parameters for creating a node for `DriverDSL.startNode`.

      See Also:
        `DriverDSL.startNode`

    - #### hashCode

          public int hashCode()

      Parameters for creating a node for `DriverDSL.startNode`.

      See Also:
        `DriverDSL.startNode`

    - #### equals

          public boolean equals(@Nullable
                                java.lang.Object p)

      Parameters for creating a node for `DriverDSL.startNode`.

      See Also:
        `DriverDSL.startNode`