Class RolloutRestriction.Builder

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

public static final class RolloutRestriction.Builder extends com.google.protobuf.GeneratedMessage.Builder<RolloutRestriction.Builder> implements RolloutRestrictionOrBuilder
 Rollout restrictions.
 
Protobuf type google.cloud.deploy.v1.RolloutRestriction
  • Method Details

    • getDescriptor

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

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage.Builder<RolloutRestriction.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<RolloutRestriction.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<RolloutRestriction.Builder>
    • getDefaultInstanceForType

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

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

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

      public RolloutRestriction.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<RolloutRestriction.Builder>
    • mergeFrom

    • isInitialized

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

      public RolloutRestriction.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<RolloutRestriction.Builder>
      Throws:
      IOException
    • getId

      public String getId()
       Required. Restriction rule ID. Required and must be unique within a
       DeployPolicy. The format is `[a-z]([a-z0-9-]{0,61}[a-z0-9])?`.
       
      string id = 1 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getId in interface RolloutRestrictionOrBuilder
      Returns:
      The id.
    • getIdBytes

      public com.google.protobuf.ByteString getIdBytes()
       Required. Restriction rule ID. Required and must be unique within a
       DeployPolicy. The format is `[a-z]([a-z0-9-]{0,61}[a-z0-9])?`.
       
      string id = 1 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getIdBytes in interface RolloutRestrictionOrBuilder
      Returns:
      The bytes for id.
    • setId

      public RolloutRestriction.Builder setId(String value)
       Required. Restriction rule ID. Required and must be unique within a
       DeployPolicy. The format is `[a-z]([a-z0-9-]{0,61}[a-z0-9])?`.
       
      string id = 1 [(.google.api.field_behavior) = REQUIRED];
      Parameters:
      value - The id to set.
      Returns:
      This builder for chaining.
    • clearId

      public RolloutRestriction.Builder clearId()
       Required. Restriction rule ID. Required and must be unique within a
       DeployPolicy. The format is `[a-z]([a-z0-9-]{0,61}[a-z0-9])?`.
       
      string id = 1 [(.google.api.field_behavior) = REQUIRED];
      Returns:
      This builder for chaining.
    • setIdBytes

      public RolloutRestriction.Builder setIdBytes(com.google.protobuf.ByteString value)
       Required. Restriction rule ID. Required and must be unique within a
       DeployPolicy. The format is `[a-z]([a-z0-9-]{0,61}[a-z0-9])?`.
       
      string id = 1 [(.google.api.field_behavior) = REQUIRED];
      Parameters:
      value - The bytes for id to set.
      Returns:
      This builder for chaining.
    • getInvokersList

      public List<DeployPolicy.Invoker> getInvokersList()
       Optional. What invoked the action. If left empty, all invoker types will be
       restricted.
       
      repeated .google.cloud.deploy.v1.DeployPolicy.Invoker invokers = 2 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getInvokersList in interface RolloutRestrictionOrBuilder
      Returns:
      A list containing the invokers.
    • getInvokersCount

      public int getInvokersCount()
       Optional. What invoked the action. If left empty, all invoker types will be
       restricted.
       
      repeated .google.cloud.deploy.v1.DeployPolicy.Invoker invokers = 2 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getInvokersCount in interface RolloutRestrictionOrBuilder
      Returns:
      The count of invokers.
    • getInvokers

      public DeployPolicy.Invoker getInvokers(int index)
       Optional. What invoked the action. If left empty, all invoker types will be
       restricted.
       
      repeated .google.cloud.deploy.v1.DeployPolicy.Invoker invokers = 2 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getInvokers in interface RolloutRestrictionOrBuilder
      Parameters:
      index - The index of the element to return.
      Returns:
      The invokers at the given index.
    • setInvokers

      public RolloutRestriction.Builder setInvokers(int index, DeployPolicy.Invoker value)
       Optional. What invoked the action. If left empty, all invoker types will be
       restricted.
       
      repeated .google.cloud.deploy.v1.DeployPolicy.Invoker invokers = 2 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      index - The index to set the value at.
      value - The invokers to set.
      Returns:
      This builder for chaining.
    • addInvokers

       Optional. What invoked the action. If left empty, all invoker types will be
       restricted.
       
      repeated .google.cloud.deploy.v1.DeployPolicy.Invoker invokers = 2 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The invokers to add.
      Returns:
      This builder for chaining.
    • addAllInvokers

      public RolloutRestriction.Builder addAllInvokers(Iterable<? extends DeployPolicy.Invoker> values)
       Optional. What invoked the action. If left empty, all invoker types will be
       restricted.
       
      repeated .google.cloud.deploy.v1.DeployPolicy.Invoker invokers = 2 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      values - The invokers to add.
      Returns:
      This builder for chaining.
    • clearInvokers

      public RolloutRestriction.Builder clearInvokers()
       Optional. What invoked the action. If left empty, all invoker types will be
       restricted.
       
      repeated .google.cloud.deploy.v1.DeployPolicy.Invoker invokers = 2 [(.google.api.field_behavior) = OPTIONAL];
      Returns:
      This builder for chaining.
    • getInvokersValueList

      public List<Integer> getInvokersValueList()
       Optional. What invoked the action. If left empty, all invoker types will be
       restricted.
       
      repeated .google.cloud.deploy.v1.DeployPolicy.Invoker invokers = 2 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getInvokersValueList in interface RolloutRestrictionOrBuilder
      Returns:
      A list containing the enum numeric values on the wire for invokers.
    • getInvokersValue

      public int getInvokersValue(int index)
       Optional. What invoked the action. If left empty, all invoker types will be
       restricted.
       
      repeated .google.cloud.deploy.v1.DeployPolicy.Invoker invokers = 2 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getInvokersValue in interface RolloutRestrictionOrBuilder
      Parameters:
      index - The index of the value to return.
      Returns:
      The enum numeric value on the wire of invokers at the given index.
    • setInvokersValue

      public RolloutRestriction.Builder setInvokersValue(int index, int value)
       Optional. What invoked the action. If left empty, all invoker types will be
       restricted.
       
      repeated .google.cloud.deploy.v1.DeployPolicy.Invoker invokers = 2 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      index - The index to set the value at.
      value - The enum numeric value on the wire for invokers to set.
      Returns:
      This builder for chaining.
    • addInvokersValue

      public RolloutRestriction.Builder addInvokersValue(int value)
       Optional. What invoked the action. If left empty, all invoker types will be
       restricted.
       
      repeated .google.cloud.deploy.v1.DeployPolicy.Invoker invokers = 2 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The enum numeric value on the wire for invokers to add.
      Returns:
      This builder for chaining.
    • addAllInvokersValue

      public RolloutRestriction.Builder addAllInvokersValue(Iterable<Integer> values)
       Optional. What invoked the action. If left empty, all invoker types will be
       restricted.
       
      repeated .google.cloud.deploy.v1.DeployPolicy.Invoker invokers = 2 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      values - The enum numeric values on the wire for invokers to add.
      Returns:
      This builder for chaining.
    • getActionsList

      public List<RolloutRestriction.RolloutActions> getActionsList()
       Optional. Rollout actions to be restricted as part of the policy. If left
       empty, all actions will be restricted.
       
      repeated .google.cloud.deploy.v1.RolloutRestriction.RolloutActions actions = 3 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getActionsList in interface RolloutRestrictionOrBuilder
      Returns:
      A list containing the actions.
    • getActionsCount

      public int getActionsCount()
       Optional. Rollout actions to be restricted as part of the policy. If left
       empty, all actions will be restricted.
       
      repeated .google.cloud.deploy.v1.RolloutRestriction.RolloutActions actions = 3 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getActionsCount in interface RolloutRestrictionOrBuilder
      Returns:
      The count of actions.
    • getActions

      public RolloutRestriction.RolloutActions getActions(int index)
       Optional. Rollout actions to be restricted as part of the policy. If left
       empty, all actions will be restricted.
       
      repeated .google.cloud.deploy.v1.RolloutRestriction.RolloutActions actions = 3 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getActions in interface RolloutRestrictionOrBuilder
      Parameters:
      index - The index of the element to return.
      Returns:
      The actions at the given index.
    • setActions

      public RolloutRestriction.Builder setActions(int index, RolloutRestriction.RolloutActions value)
       Optional. Rollout actions to be restricted as part of the policy. If left
       empty, all actions will be restricted.
       
      repeated .google.cloud.deploy.v1.RolloutRestriction.RolloutActions actions = 3 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      index - The index to set the value at.
      value - The actions to set.
      Returns:
      This builder for chaining.
    • addActions

       Optional. Rollout actions to be restricted as part of the policy. If left
       empty, all actions will be restricted.
       
      repeated .google.cloud.deploy.v1.RolloutRestriction.RolloutActions actions = 3 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The actions to add.
      Returns:
      This builder for chaining.
    • addAllActions

      public RolloutRestriction.Builder addAllActions(Iterable<? extends RolloutRestriction.RolloutActions> values)
       Optional. Rollout actions to be restricted as part of the policy. If left
       empty, all actions will be restricted.
       
      repeated .google.cloud.deploy.v1.RolloutRestriction.RolloutActions actions = 3 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      values - The actions to add.
      Returns:
      This builder for chaining.
    • clearActions

      public RolloutRestriction.Builder clearActions()
       Optional. Rollout actions to be restricted as part of the policy. If left
       empty, all actions will be restricted.
       
      repeated .google.cloud.deploy.v1.RolloutRestriction.RolloutActions actions = 3 [(.google.api.field_behavior) = OPTIONAL];
      Returns:
      This builder for chaining.
    • getActionsValueList

      public List<Integer> getActionsValueList()
       Optional. Rollout actions to be restricted as part of the policy. If left
       empty, all actions will be restricted.
       
      repeated .google.cloud.deploy.v1.RolloutRestriction.RolloutActions actions = 3 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getActionsValueList in interface RolloutRestrictionOrBuilder
      Returns:
      A list containing the enum numeric values on the wire for actions.
    • getActionsValue

      public int getActionsValue(int index)
       Optional. Rollout actions to be restricted as part of the policy. If left
       empty, all actions will be restricted.
       
      repeated .google.cloud.deploy.v1.RolloutRestriction.RolloutActions actions = 3 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getActionsValue in interface RolloutRestrictionOrBuilder
      Parameters:
      index - The index of the value to return.
      Returns:
      The enum numeric value on the wire of actions at the given index.
    • setActionsValue

      public RolloutRestriction.Builder setActionsValue(int index, int value)
       Optional. Rollout actions to be restricted as part of the policy. If left
       empty, all actions will be restricted.
       
      repeated .google.cloud.deploy.v1.RolloutRestriction.RolloutActions actions = 3 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      index - The index to set the value at.
      value - The enum numeric value on the wire for actions to set.
      Returns:
      This builder for chaining.
    • addActionsValue

      public RolloutRestriction.Builder addActionsValue(int value)
       Optional. Rollout actions to be restricted as part of the policy. If left
       empty, all actions will be restricted.
       
      repeated .google.cloud.deploy.v1.RolloutRestriction.RolloutActions actions = 3 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The enum numeric value on the wire for actions to add.
      Returns:
      This builder for chaining.
    • addAllActionsValue

      public RolloutRestriction.Builder addAllActionsValue(Iterable<Integer> values)
       Optional. Rollout actions to be restricted as part of the policy. If left
       empty, all actions will be restricted.
       
      repeated .google.cloud.deploy.v1.RolloutRestriction.RolloutActions actions = 3 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      values - The enum numeric values on the wire for actions to add.
      Returns:
      This builder for chaining.
    • hasTimeWindows

      public boolean hasTimeWindows()
       Required. Time window within which actions are restricted.
       
      .google.cloud.deploy.v1.TimeWindows time_windows = 4 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      hasTimeWindows in interface RolloutRestrictionOrBuilder
      Returns:
      Whether the timeWindows field is set.
    • getTimeWindows

      public TimeWindows getTimeWindows()
       Required. Time window within which actions are restricted.
       
      .google.cloud.deploy.v1.TimeWindows time_windows = 4 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getTimeWindows in interface RolloutRestrictionOrBuilder
      Returns:
      The timeWindows.
    • setTimeWindows

      public RolloutRestriction.Builder setTimeWindows(TimeWindows value)
       Required. Time window within which actions are restricted.
       
      .google.cloud.deploy.v1.TimeWindows time_windows = 4 [(.google.api.field_behavior) = REQUIRED];
    • setTimeWindows

      public RolloutRestriction.Builder setTimeWindows(TimeWindows.Builder builderForValue)
       Required. Time window within which actions are restricted.
       
      .google.cloud.deploy.v1.TimeWindows time_windows = 4 [(.google.api.field_behavior) = REQUIRED];
    • mergeTimeWindows

      public RolloutRestriction.Builder mergeTimeWindows(TimeWindows value)
       Required. Time window within which actions are restricted.
       
      .google.cloud.deploy.v1.TimeWindows time_windows = 4 [(.google.api.field_behavior) = REQUIRED];
    • clearTimeWindows

      public RolloutRestriction.Builder clearTimeWindows()
       Required. Time window within which actions are restricted.
       
      .google.cloud.deploy.v1.TimeWindows time_windows = 4 [(.google.api.field_behavior) = REQUIRED];
    • getTimeWindowsBuilder

      public TimeWindows.Builder getTimeWindowsBuilder()
       Required. Time window within which actions are restricted.
       
      .google.cloud.deploy.v1.TimeWindows time_windows = 4 [(.google.api.field_behavior) = REQUIRED];
    • getTimeWindowsOrBuilder

      public TimeWindowsOrBuilder getTimeWindowsOrBuilder()
       Required. Time window within which actions are restricted.
       
      .google.cloud.deploy.v1.TimeWindows time_windows = 4 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getTimeWindowsOrBuilder in interface RolloutRestrictionOrBuilder