Class NodeBuilder

java.lang.Object
io.atomix.cluster.NodeBuilder
All Implemented Interfaces:
Builder<Node>
Direct Known Subclasses:
MemberBuilder

public class NodeBuilder extends Object implements Builder<Node>
Node builder.
  • Field Details

  • Constructor Details

    • NodeBuilder

      protected NodeBuilder(NodeConfig config)
  • Method Details

    • withId

      public NodeBuilder withId(String id)
      Sets the node identifier.
      Parameters:
      id - the node identifier
      Returns:
      the node builder
    • withId

      public NodeBuilder withId(NodeId id)
      Sets the node identifier.
      Parameters:
      id - the node identifier
      Returns:
      the node builder
    • withHost

      public NodeBuilder withHost(String host)
      Sets the node host.
      Parameters:
      host - the node host
      Returns:
      the node builder
    • withPort

      public NodeBuilder withPort(int port)
      Sets the node port.
      Parameters:
      port - the node port
      Returns:
      the node builder
    • withAddress

      public NodeBuilder withAddress(Address address)
      Sets the node address.
      Parameters:
      address - the node address
      Returns:
      the node builder
    • build

      public Node build()
      Specified by:
      build in interface Builder<Node>