Class Reservation.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<Reservation.Builder>
com.google.cloud.tpu.v2alpha1.Reservation.Builder
All Implemented Interfaces:
ReservationOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
Reservation

public static final class Reservation.Builder extends com.google.protobuf.GeneratedMessage.Builder<Reservation.Builder> implements ReservationOrBuilder
 A reservation describes the amount of a resource 'allotted' for a defined
 period of time.
 
Protobuf type google.cloud.tpu.v2alpha1.Reservation
  • 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<Reservation.Builder>
    • clear

      public Reservation.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<Reservation.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<Reservation.Builder>
    • getDefaultInstanceForType

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

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

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

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

      public Reservation.Builder mergeFrom(Reservation other)
    • isInitialized

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

      public Reservation.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<Reservation.Builder>
      Throws:
      IOException
    • getKindCase

      public Reservation.KindCase getKindCase()
      Specified by:
      getKindCase in interface ReservationOrBuilder
    • clearKind

      public Reservation.Builder clearKind()
    • getName

      public String getName()
       The reservation name with the format:
       projects/{projectID}/locations/{location}/reservations/{reservationID}
       
      string name = 1;
      Specified by:
      getName in interface ReservationOrBuilder
      Returns:
      The name.
    • getNameBytes

      public com.google.protobuf.ByteString getNameBytes()
       The reservation name with the format:
       projects/{projectID}/locations/{location}/reservations/{reservationID}
       
      string name = 1;
      Specified by:
      getNameBytes in interface ReservationOrBuilder
      Returns:
      The bytes for name.
    • setName

      public Reservation.Builder setName(String value)
       The reservation name with the format:
       projects/{projectID}/locations/{location}/reservations/{reservationID}
       
      string name = 1;
      Parameters:
      value - The name to set.
      Returns:
      This builder for chaining.
    • clearName

      public Reservation.Builder clearName()
       The reservation name with the format:
       projects/{projectID}/locations/{location}/reservations/{reservationID}
       
      string name = 1;
      Returns:
      This builder for chaining.
    • setNameBytes

      public Reservation.Builder setNameBytes(com.google.protobuf.ByteString value)
       The reservation name with the format:
       projects/{projectID}/locations/{location}/reservations/{reservationID}
       
      string name = 1;
      Parameters:
      value - The bytes for name to set.
      Returns:
      This builder for chaining.
    • hasStandard

      public boolean hasStandard()
       A standard reservation.
       
      .google.cloud.tpu.v2alpha1.Reservation.Standard standard = 2;
      Specified by:
      hasStandard in interface ReservationOrBuilder
      Returns:
      Whether the standard field is set.
    • getStandard

      public Reservation.Standard getStandard()
       A standard reservation.
       
      .google.cloud.tpu.v2alpha1.Reservation.Standard standard = 2;
      Specified by:
      getStandard in interface ReservationOrBuilder
      Returns:
      The standard.
    • setStandard

      public Reservation.Builder setStandard(Reservation.Standard value)
       A standard reservation.
       
      .google.cloud.tpu.v2alpha1.Reservation.Standard standard = 2;
    • setStandard

      public Reservation.Builder setStandard(Reservation.Standard.Builder builderForValue)
       A standard reservation.
       
      .google.cloud.tpu.v2alpha1.Reservation.Standard standard = 2;
    • mergeStandard

      public Reservation.Builder mergeStandard(Reservation.Standard value)
       A standard reservation.
       
      .google.cloud.tpu.v2alpha1.Reservation.Standard standard = 2;
    • clearStandard

      public Reservation.Builder clearStandard()
       A standard reservation.
       
      .google.cloud.tpu.v2alpha1.Reservation.Standard standard = 2;
    • getStandardBuilder

      public Reservation.Standard.Builder getStandardBuilder()
       A standard reservation.
       
      .google.cloud.tpu.v2alpha1.Reservation.Standard standard = 2;
    • getStandardOrBuilder

      public Reservation.StandardOrBuilder getStandardOrBuilder()
       A standard reservation.
       
      .google.cloud.tpu.v2alpha1.Reservation.Standard standard = 2;
      Specified by:
      getStandardOrBuilder in interface ReservationOrBuilder
    • getStateValue

      public int getStateValue()
       Output only. The state of the Reservation.
       
      .google.cloud.tpu.v2alpha1.Reservation.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getStateValue in interface ReservationOrBuilder
      Returns:
      The enum numeric value on the wire for state.
    • setStateValue

      public Reservation.Builder setStateValue(int value)
       Output only. The state of the Reservation.
       
      .google.cloud.tpu.v2alpha1.Reservation.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Parameters:
      value - The enum numeric value on the wire for state to set.
      Returns:
      This builder for chaining.
    • getState

      public Reservation.State getState()
       Output only. The state of the Reservation.
       
      .google.cloud.tpu.v2alpha1.Reservation.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getState in interface ReservationOrBuilder
      Returns:
      The state.
    • setState

      public Reservation.Builder setState(Reservation.State value)
       Output only. The state of the Reservation.
       
      .google.cloud.tpu.v2alpha1.Reservation.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Parameters:
      value - The state to set.
      Returns:
      This builder for chaining.
    • clearState

      public Reservation.Builder clearState()
       Output only. The state of the Reservation.
       
      .google.cloud.tpu.v2alpha1.Reservation.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Returns:
      This builder for chaining.