Class ServiceEndpoint.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder<ServiceEndpoint,ServiceEndpoint.Builder>
com.google.protobuf.GeneratedMessageLite.Builder<ServiceEndpoint,ServiceEndpoint.Builder>
com.hedera.hashgraph.sdk.proto.ServiceEndpoint.Builder
All Implemented Interfaces:
com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, ServiceEndpointOrBuilder, Cloneable
Enclosing class:
ServiceEndpoint

public static final class ServiceEndpoint.Builder extends com.google.protobuf.GeneratedMessageLite.Builder<ServiceEndpoint,ServiceEndpoint.Builder> implements ServiceEndpointOrBuilder
 *
 A network node endpoint.<br/>
 Each network node in the global address book publishes one or more endpoints
 which enable the nodes to communicate both with other nodes, for gossip, and
 with clients to receive transaction requests.

 This message supports IPv4 with address and TCP port,
 and MAY include a FQDN instead of an IP address.<br/>
 IPv6 is not currently supported.

 When the `domain_name` field is set, the `ipAddressV4` field
 MUST NOT be set.<br/>
 When the `ipAddressV4` field is set, the `domain_name` field
 MUST NOT be set.
 
Protobuf type proto.ServiceEndpoint
  • Field Summary

    Fields inherited from class com.google.protobuf.GeneratedMessageLite.Builder

    instance
  • Method Summary

    Modifier and Type
    Method
    Description
    * A node domain name.
    * A 32-bit IPv4 address.<br/> This is the address of the endpoint, encoded in pure "big-endian" (i.e.
    * A TCP port to use.
    * A node domain name.
    com.google.protobuf.ByteString
    * A node domain name.
    com.google.protobuf.ByteString
    * A 32-bit IPv4 address.<br/> This is the address of the endpoint, encoded in pure "big-endian" (i.e.
    int
    * A TCP port to use.
    * A node domain name.
    setDomainNameBytes(com.google.protobuf.ByteString value)
    * A node domain name.
    setIpAddressV4(com.google.protobuf.ByteString value)
    * A 32-bit IPv4 address.<br/> This is the address of the endpoint, encoded in pure "big-endian" (i.e.
    setPort(int value)
    * A TCP port to use.

    Methods inherited from class com.google.protobuf.GeneratedMessageLite.Builder

    build, buildPartial, clear, clone, copyOnWrite, copyOnWriteInternal, getDefaultInstanceForType, internalMergeFrom, isInitialized, mergeFrom, mergeFrom, mergeFrom, mergeFrom

    Methods inherited from class com.google.protobuf.AbstractMessageLite.Builder

    addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException

    Methods inherited from class java.lang.Object

    equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface com.google.protobuf.MessageLiteOrBuilder

    getDefaultInstanceForType, isInitialized
  • Method Details

    • getIpAddressV4

      public com.google.protobuf.ByteString getIpAddressV4()
       *
       A 32-bit IPv4 address.<br/>
       This is the address of the endpoint, encoded in pure "big-endian"
       (i.e. left to right) order (e.g. `127.0.0.1` has hex bytes in the
       order `7F`, `00`, `00`, `01`).
       
      bytes ipAddressV4 = 1;
      Specified by:
      getIpAddressV4 in interface ServiceEndpointOrBuilder
      Returns:
      The ipAddressV4.
    • setIpAddressV4

      public ServiceEndpoint.Builder setIpAddressV4(com.google.protobuf.ByteString value)
       *
       A 32-bit IPv4 address.<br/>
       This is the address of the endpoint, encoded in pure "big-endian"
       (i.e. left to right) order (e.g. `127.0.0.1` has hex bytes in the
       order `7F`, `00`, `00`, `01`).
       
      bytes ipAddressV4 = 1;
      Parameters:
      value - The ipAddressV4 to set.
      Returns:
      This builder for chaining.
    • clearIpAddressV4

      public ServiceEndpoint.Builder clearIpAddressV4()
       *
       A 32-bit IPv4 address.<br/>
       This is the address of the endpoint, encoded in pure "big-endian"
       (i.e. left to right) order (e.g. `127.0.0.1` has hex bytes in the
       order `7F`, `00`, `00`, `01`).
       
      bytes ipAddressV4 = 1;
      Returns:
      This builder for chaining.
    • getPort

      public int getPort()
       *
       A TCP port to use.
       <p>
       This value MUST be between 0 and 65535, inclusive.
       
      int32 port = 2;
      Specified by:
      getPort in interface ServiceEndpointOrBuilder
      Returns:
      The port.
    • setPort

      public ServiceEndpoint.Builder setPort(int value)
       *
       A TCP port to use.
       <p>
       This value MUST be between 0 and 65535, inclusive.
       
      int32 port = 2;
      Parameters:
      value - The port to set.
      Returns:
      This builder for chaining.
    • clearPort

      public ServiceEndpoint.Builder clearPort()
       *
       A TCP port to use.
       <p>
       This value MUST be between 0 and 65535, inclusive.
       
      int32 port = 2;
      Returns:
      This builder for chaining.
    • getDomainName

      public String getDomainName()
       *
       A node domain name.
       <p>
       This MUST be the fully qualified domain name of the node.<br/>
       This value MUST NOT exceed 253 characters.<br/>
       When the `domain_name` field is set, the `ipAddressV4`
       field MUST NOT be set.<br/>
       When the `ipAddressV4` field is set, the `domain_name`
       field MUST NOT be set.
       
      string domain_name = 3;
      Specified by:
      getDomainName in interface ServiceEndpointOrBuilder
      Returns:
      The domainName.
    • getDomainNameBytes

      public com.google.protobuf.ByteString getDomainNameBytes()
       *
       A node domain name.
       <p>
       This MUST be the fully qualified domain name of the node.<br/>
       This value MUST NOT exceed 253 characters.<br/>
       When the `domain_name` field is set, the `ipAddressV4`
       field MUST NOT be set.<br/>
       When the `ipAddressV4` field is set, the `domain_name`
       field MUST NOT be set.
       
      string domain_name = 3;
      Specified by:
      getDomainNameBytes in interface ServiceEndpointOrBuilder
      Returns:
      The bytes for domainName.
    • setDomainName

      public ServiceEndpoint.Builder setDomainName(String value)
       *
       A node domain name.
       <p>
       This MUST be the fully qualified domain name of the node.<br/>
       This value MUST NOT exceed 253 characters.<br/>
       When the `domain_name` field is set, the `ipAddressV4`
       field MUST NOT be set.<br/>
       When the `ipAddressV4` field is set, the `domain_name`
       field MUST NOT be set.
       
      string domain_name = 3;
      Parameters:
      value - The domainName to set.
      Returns:
      This builder for chaining.
    • clearDomainName

      public ServiceEndpoint.Builder clearDomainName()
       *
       A node domain name.
       <p>
       This MUST be the fully qualified domain name of the node.<br/>
       This value MUST NOT exceed 253 characters.<br/>
       When the `domain_name` field is set, the `ipAddressV4`
       field MUST NOT be set.<br/>
       When the `ipAddressV4` field is set, the `domain_name`
       field MUST NOT be set.
       
      string domain_name = 3;
      Returns:
      This builder for chaining.
    • setDomainNameBytes

      public ServiceEndpoint.Builder setDomainNameBytes(com.google.protobuf.ByteString value)
       *
       A node domain name.
       <p>
       This MUST be the fully qualified domain name of the node.<br/>
       This value MUST NOT exceed 253 characters.<br/>
       When the `domain_name` field is set, the `ipAddressV4`
       field MUST NOT be set.<br/>
       When the `ipAddressV4` field is set, the `domain_name`
       field MUST NOT be set.
       
      string domain_name = 3;
      Parameters:
      value - The bytes for domainName to set.
      Returns:
      This builder for chaining.