Class Mesh.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<Mesh.Builder>
com.google.cloud.networkservices.v1.Mesh.Builder
All Implemented Interfaces:
MeshOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
Mesh

public static final class Mesh.Builder extends com.google.protobuf.GeneratedMessage.Builder<Mesh.Builder> implements MeshOrBuilder
 Mesh represents a logical configuration grouping for workload to workload
 communication within a service mesh. Routes that point to mesh dictate how
 requests are routed within this logical mesh boundary.
 
Protobuf type google.cloud.networkservices.v1.Mesh
  • Method Details

    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetMapFieldReflection

      protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
      Overrides:
      internalGetMapFieldReflection in class com.google.protobuf.GeneratedMessage.Builder<Mesh.Builder>
    • internalGetMutableMapFieldReflection

      protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFieldReflection(int number)
      Overrides:
      internalGetMutableMapFieldReflection in class com.google.protobuf.GeneratedMessage.Builder<Mesh.Builder>
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage.Builder<Mesh.Builder>
    • clear

      public Mesh.Builder clear()
      Specified by:
      clear in interface com.google.protobuf.Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class com.google.protobuf.GeneratedMessage.Builder<Mesh.Builder>
    • getDescriptorForType

      public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface com.google.protobuf.Message.Builder
      Specified by:
      getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class com.google.protobuf.GeneratedMessage.Builder<Mesh.Builder>
    • getDefaultInstanceForType

      public Mesh getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
    • build

      public Mesh build()
      Specified by:
      build in interface com.google.protobuf.Message.Builder
      Specified by:
      build in interface com.google.protobuf.MessageLite.Builder
    • buildPartial

      public Mesh buildPartial()
      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • mergeFrom

      public Mesh.Builder mergeFrom(com.google.protobuf.Message other)
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<Mesh.Builder>
    • mergeFrom

      public Mesh.Builder mergeFrom(Mesh other)
    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessage.Builder<Mesh.Builder>
    • mergeFrom

      public Mesh.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Specified by:
      mergeFrom in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<Mesh.Builder>
      Throws:
      IOException
    • getName

      public String getName()
       Identifier. Name of the Mesh resource. It matches pattern
       `projects/*/locations/global/meshes/<mesh_name>`.
       
      string name = 1 [(.google.api.field_behavior) = IDENTIFIER];
      Specified by:
      getName in interface MeshOrBuilder
      Returns:
      The name.
    • getNameBytes

      public com.google.protobuf.ByteString getNameBytes()
       Identifier. Name of the Mesh resource. It matches pattern
       `projects/*/locations/global/meshes/<mesh_name>`.
       
      string name = 1 [(.google.api.field_behavior) = IDENTIFIER];
      Specified by:
      getNameBytes in interface MeshOrBuilder
      Returns:
      The bytes for name.
    • setName

      public Mesh.Builder setName(String value)
       Identifier. Name of the Mesh resource. It matches pattern
       `projects/*/locations/global/meshes/<mesh_name>`.
       
      string name = 1 [(.google.api.field_behavior) = IDENTIFIER];
      Parameters:
      value - The name to set.
      Returns:
      This builder for chaining.
    • clearName

      public Mesh.Builder clearName()
       Identifier. Name of the Mesh resource. It matches pattern
       `projects/*/locations/global/meshes/<mesh_name>`.
       
      string name = 1 [(.google.api.field_behavior) = IDENTIFIER];
      Returns:
      This builder for chaining.
    • setNameBytes

      public Mesh.Builder setNameBytes(com.google.protobuf.ByteString value)
       Identifier. Name of the Mesh resource. It matches pattern
       `projects/*/locations/global/meshes/<mesh_name>`.
       
      string name = 1 [(.google.api.field_behavior) = IDENTIFIER];
      Parameters:
      value - The bytes for name to set.
      Returns:
      This builder for chaining.
    • getSelfLink

      public String getSelfLink()
       Output only. Server-defined URL of this resource
       
      string self_link = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getSelfLink in interface MeshOrBuilder
      Returns:
      The selfLink.
    • getSelfLinkBytes

      public com.google.protobuf.ByteString getSelfLinkBytes()
       Output only. Server-defined URL of this resource
       
      string self_link = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getSelfLinkBytes in interface MeshOrBuilder
      Returns:
      The bytes for selfLink.
    • setSelfLink

      public Mesh.Builder setSelfLink(String value)
       Output only. Server-defined URL of this resource
       
      string self_link = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Parameters:
      value - The selfLink to set.
      Returns:
      This builder for chaining.
    • clearSelfLink

      public Mesh.Builder clearSelfLink()
       Output only. Server-defined URL of this resource
       
      string self_link = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Returns:
      This builder for chaining.
    • setSelfLinkBytes

      public Mesh.Builder setSelfLinkBytes(com.google.protobuf.ByteString value)
       Output only. Server-defined URL of this resource
       
      string self_link = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Parameters:
      value - The bytes for selfLink to set.
      Returns:
      This builder for chaining.
    • hasCreateTime

      public boolean hasCreateTime()
       Output only. The timestamp when the resource was created.
       
      .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      hasCreateTime in interface MeshOrBuilder
      Returns:
      Whether the createTime field is set.
    • getCreateTime

      public com.google.protobuf.Timestamp getCreateTime()
       Output only. The timestamp when the resource was created.
       
      .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getCreateTime in interface MeshOrBuilder
      Returns:
      The createTime.
    • setCreateTime

      public Mesh.Builder setCreateTime(com.google.protobuf.Timestamp value)
       Output only. The timestamp when the resource was created.
       
      .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • setCreateTime

      public Mesh.Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue)
       Output only. The timestamp when the resource was created.
       
      .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • mergeCreateTime

      public Mesh.Builder mergeCreateTime(com.google.protobuf.Timestamp value)
       Output only. The timestamp when the resource was created.
       
      .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • clearCreateTime

      public Mesh.Builder clearCreateTime()
       Output only. The timestamp when the resource was created.
       
      .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • getCreateTimeBuilder

      public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder()
       Output only. The timestamp when the resource was created.
       
      .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • getCreateTimeOrBuilder

      public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder()
       Output only. The timestamp when the resource was created.
       
      .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getCreateTimeOrBuilder in interface MeshOrBuilder
    • hasUpdateTime

      public boolean hasUpdateTime()
       Output only. The timestamp when the resource was updated.
       
      .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      hasUpdateTime in interface MeshOrBuilder
      Returns:
      Whether the updateTime field is set.
    • getUpdateTime

      public com.google.protobuf.Timestamp getUpdateTime()
       Output only. The timestamp when the resource was updated.
       
      .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getUpdateTime in interface MeshOrBuilder
      Returns:
      The updateTime.
    • setUpdateTime

      public Mesh.Builder setUpdateTime(com.google.protobuf.Timestamp value)
       Output only. The timestamp when the resource was updated.
       
      .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • setUpdateTime

      public Mesh.Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue)
       Output only. The timestamp when the resource was updated.
       
      .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • mergeUpdateTime

      public Mesh.Builder mergeUpdateTime(com.google.protobuf.Timestamp value)
       Output only. The timestamp when the resource was updated.
       
      .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • clearUpdateTime

      public Mesh.Builder clearUpdateTime()
       Output only. The timestamp when the resource was updated.
       
      .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • getUpdateTimeBuilder

      public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder()
       Output only. The timestamp when the resource was updated.
       
      .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • getUpdateTimeOrBuilder

      public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder()
       Output only. The timestamp when the resource was updated.
       
      .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getUpdateTimeOrBuilder in interface MeshOrBuilder
    • getLabelsCount

      public int getLabelsCount()
      Description copied from interface: MeshOrBuilder
       Optional. Set of label tags associated with the Mesh resource.
       
      map<string, string> labels = 4 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getLabelsCount in interface MeshOrBuilder
    • containsLabels

      public boolean containsLabels(String key)
       Optional. Set of label tags associated with the Mesh resource.
       
      map<string, string> labels = 4 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      containsLabels in interface MeshOrBuilder
    • getLabels

      @Deprecated public Map<String,String> getLabels()
      Deprecated.
      Use getLabelsMap() instead.
      Specified by:
      getLabels in interface MeshOrBuilder
    • getLabelsMap

      public Map<String,String> getLabelsMap()
       Optional. Set of label tags associated with the Mesh resource.
       
      map<string, string> labels = 4 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getLabelsMap in interface MeshOrBuilder
    • getLabelsOrDefault

      public String getLabelsOrDefault(String key, String defaultValue)
       Optional. Set of label tags associated with the Mesh resource.
       
      map<string, string> labels = 4 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getLabelsOrDefault in interface MeshOrBuilder
    • getLabelsOrThrow

      public String getLabelsOrThrow(String key)
       Optional. Set of label tags associated with the Mesh resource.
       
      map<string, string> labels = 4 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getLabelsOrThrow in interface MeshOrBuilder
    • clearLabels

      public Mesh.Builder clearLabels()
    • removeLabels

      public Mesh.Builder removeLabels(String key)
       Optional. Set of label tags associated with the Mesh resource.
       
      map<string, string> labels = 4 [(.google.api.field_behavior) = OPTIONAL];
    • getMutableLabels

      @Deprecated public Map<String,String> getMutableLabels()
      Deprecated.
      Use alternate mutation accessors instead.
    • putLabels

      public Mesh.Builder putLabels(String key, String value)
       Optional. Set of label tags associated with the Mesh resource.
       
      map<string, string> labels = 4 [(.google.api.field_behavior) = OPTIONAL];
    • putAllLabels

      public Mesh.Builder putAllLabels(Map<String,String> values)
       Optional. Set of label tags associated with the Mesh resource.
       
      map<string, string> labels = 4 [(.google.api.field_behavior) = OPTIONAL];
    • getDescription

      public String getDescription()
       Optional. A free-text description of the resource. Max length 1024
       characters.
       
      string description = 5 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getDescription in interface MeshOrBuilder
      Returns:
      The description.
    • getDescriptionBytes

      public com.google.protobuf.ByteString getDescriptionBytes()
       Optional. A free-text description of the resource. Max length 1024
       characters.
       
      string description = 5 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getDescriptionBytes in interface MeshOrBuilder
      Returns:
      The bytes for description.
    • setDescription

      public Mesh.Builder setDescription(String value)
       Optional. A free-text description of the resource. Max length 1024
       characters.
       
      string description = 5 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The description to set.
      Returns:
      This builder for chaining.
    • clearDescription

      public Mesh.Builder clearDescription()
       Optional. A free-text description of the resource. Max length 1024
       characters.
       
      string description = 5 [(.google.api.field_behavior) = OPTIONAL];
      Returns:
      This builder for chaining.
    • setDescriptionBytes

      public Mesh.Builder setDescriptionBytes(com.google.protobuf.ByteString value)
       Optional. A free-text description of the resource. Max length 1024
       characters.
       
      string description = 5 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The bytes for description to set.
      Returns:
      This builder for chaining.
    • getInterceptionPort

      public int getInterceptionPort()
       Optional. If set to a valid TCP port (1-65535), instructs the SIDECAR proxy
       to listen on the specified port of localhost (127.0.0.1) address. The
       SIDECAR proxy will expect all traffic to be redirected to this port
       regardless of its actual ip:port destination. If unset, a port '15001' is
       used as the interception port. This is applicable only for sidecar proxy
       deployments.
       
      int32 interception_port = 8 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getInterceptionPort in interface MeshOrBuilder
      Returns:
      The interceptionPort.
    • setInterceptionPort

      public Mesh.Builder setInterceptionPort(int value)
       Optional. If set to a valid TCP port (1-65535), instructs the SIDECAR proxy
       to listen on the specified port of localhost (127.0.0.1) address. The
       SIDECAR proxy will expect all traffic to be redirected to this port
       regardless of its actual ip:port destination. If unset, a port '15001' is
       used as the interception port. This is applicable only for sidecar proxy
       deployments.
       
      int32 interception_port = 8 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The interceptionPort to set.
      Returns:
      This builder for chaining.
    • clearInterceptionPort

      public Mesh.Builder clearInterceptionPort()
       Optional. If set to a valid TCP port (1-65535), instructs the SIDECAR proxy
       to listen on the specified port of localhost (127.0.0.1) address. The
       SIDECAR proxy will expect all traffic to be redirected to this port
       regardless of its actual ip:port destination. If unset, a port '15001' is
       used as the interception port. This is applicable only for sidecar proxy
       deployments.
       
      int32 interception_port = 8 [(.google.api.field_behavior) = OPTIONAL];
      Returns:
      This builder for chaining.
    • hasEnvoyHeaders

      public boolean hasEnvoyHeaders()
       Optional. Determines if envoy will insert internal debug headers into
       upstream requests. Other Envoy headers may still be injected. By default,
       envoy will not insert any debug headers.
       
      optional .google.cloud.networkservices.v1.EnvoyHeaders envoy_headers = 16 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      hasEnvoyHeaders in interface MeshOrBuilder
      Returns:
      Whether the envoyHeaders field is set.
    • getEnvoyHeadersValue

      public int getEnvoyHeadersValue()
       Optional. Determines if envoy will insert internal debug headers into
       upstream requests. Other Envoy headers may still be injected. By default,
       envoy will not insert any debug headers.
       
      optional .google.cloud.networkservices.v1.EnvoyHeaders envoy_headers = 16 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getEnvoyHeadersValue in interface MeshOrBuilder
      Returns:
      The enum numeric value on the wire for envoyHeaders.
    • setEnvoyHeadersValue

      public Mesh.Builder setEnvoyHeadersValue(int value)
       Optional. Determines if envoy will insert internal debug headers into
       upstream requests. Other Envoy headers may still be injected. By default,
       envoy will not insert any debug headers.
       
      optional .google.cloud.networkservices.v1.EnvoyHeaders envoy_headers = 16 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The enum numeric value on the wire for envoyHeaders to set.
      Returns:
      This builder for chaining.
    • getEnvoyHeaders

      public EnvoyHeaders getEnvoyHeaders()
       Optional. Determines if envoy will insert internal debug headers into
       upstream requests. Other Envoy headers may still be injected. By default,
       envoy will not insert any debug headers.
       
      optional .google.cloud.networkservices.v1.EnvoyHeaders envoy_headers = 16 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getEnvoyHeaders in interface MeshOrBuilder
      Returns:
      The envoyHeaders.
    • setEnvoyHeaders

      public Mesh.Builder setEnvoyHeaders(EnvoyHeaders value)
       Optional. Determines if envoy will insert internal debug headers into
       upstream requests. Other Envoy headers may still be injected. By default,
       envoy will not insert any debug headers.
       
      optional .google.cloud.networkservices.v1.EnvoyHeaders envoy_headers = 16 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The envoyHeaders to set.
      Returns:
      This builder for chaining.
    • clearEnvoyHeaders

      public Mesh.Builder clearEnvoyHeaders()
       Optional. Determines if envoy will insert internal debug headers into
       upstream requests. Other Envoy headers may still be injected. By default,
       envoy will not insert any debug headers.
       
      optional .google.cloud.networkservices.v1.EnvoyHeaders envoy_headers = 16 [(.google.api.field_behavior) = OPTIONAL];
      Returns:
      This builder for chaining.