Class ImmutableNetworkDescription.Builder

java.lang.Object
fr.enedis.chutney.agent.domain.network.ImmutableNetworkDescription.Builder
Enclosing class:
ImmutableNetworkDescription

@Generated(from="NetworkDescription", generator="Immutables") @NotThreadSafe public static final class ImmutableNetworkDescription.Builder extends Object
Builds instances of type ImmutableNetworkDescription. Initialize attributes and then invoke the build() method to create an immutable instance.

Builder is not thread-safe and generally should not be stored in a field or collection, but instead used immediately to create instances.

  • Method Details

    • from

      @CanIgnoreReturnValue public final ImmutableNetworkDescription.Builder from(NetworkDescription instance)
      Fill a builder with attribute values from the provided NetworkDescription instance. Regular attribute values will be replaced with those from the given instance. Absent optional values will not replace present values.
      Parameters:
      instance - The instance from which to copy values
      Returns:
      this builder for use in a chained invocation
    • configuration

      @CanIgnoreReturnValue public final ImmutableNetworkDescription.Builder configuration(NetworkConfiguration configuration)
      Initializes the value for the configuration attribute.
      Parameters:
      configuration - The value for configuration
      Returns:
      this builder for use in a chained invocation
    • agentGraph

      @CanIgnoreReturnValue public final ImmutableNetworkDescription.Builder agentGraph(AgentGraph agentGraph)
      Initializes the value for the agentGraph attribute.
      Parameters:
      agentGraph - The value for agentGraph
      Returns:
      this builder for use in a chained invocation
    • localAgent

      @CanIgnoreReturnValue public final ImmutableNetworkDescription.Builder localAgent(Agent localAgent)
      Initializes the optional value localAgent to localAgent.
      Parameters:
      localAgent - The value for localAgent
      Returns:
      this builder for chained invocation
    • localAgent

      @CanIgnoreReturnValue public final ImmutableNetworkDescription.Builder localAgent(Optional<? extends Agent> localAgent)
      Initializes the optional value localAgent to localAgent.
      Parameters:
      localAgent - The value for localAgent
      Returns:
      this builder for use in a chained invocation
    • build

      Returns:
      An immutable instance of NetworkDescription
      Throws:
      IllegalStateException - if any required attributes are missing