Class AllocationPolicy.LocationPolicy

java.lang.Object
com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessage
com.google.protobuf.GeneratedMessage
com.google.cloud.batch.v1alpha.AllocationPolicy.LocationPolicy
All Implemented Interfaces:
AllocationPolicy.LocationPolicyOrBuilder, com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Serializable
Enclosing class:
AllocationPolicy

public static final class AllocationPolicy.LocationPolicy extends com.google.protobuf.GeneratedMessage implements AllocationPolicy.LocationPolicyOrBuilder
Protobuf type google.cloud.batch.v1alpha.AllocationPolicy.LocationPolicy
See Also:
  • Field Details

    • ALLOWED_LOCATIONS_FIELD_NUMBER

      public static final int ALLOWED_LOCATIONS_FIELD_NUMBER
      See Also:
    • DENIED_LOCATIONS_FIELD_NUMBER

      public static final int DENIED_LOCATIONS_FIELD_NUMBER
      See Also:
  • 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
    • getAllowedLocationsList

      public com.google.protobuf.ProtocolStringList getAllowedLocationsList()
       A list of allowed location names represented by internal URLs.
      
       Each location can be a region or a zone.
       Only one region or multiple zones in one region is supported now.
       For example,
       ["regions/us-central1"] allow VMs in any zones in region us-central1.
       ["zones/us-central1-a", "zones/us-central1-c"] only allow VMs
       in zones us-central1-a and us-central1-c.
      
       Mixing locations from different regions would cause errors.
       For example,
       ["regions/us-central1", "zones/us-central1-a", "zones/us-central1-b",
       "zones/us-west1-a"] contains locations from two distinct regions:
       us-central1 and us-west1. This combination will trigger an error.
       
      repeated string allowed_locations = 1;
      Specified by:
      getAllowedLocationsList in interface AllocationPolicy.LocationPolicyOrBuilder
      Returns:
      A list containing the allowedLocations.
    • getAllowedLocationsCount

      public int getAllowedLocationsCount()
       A list of allowed location names represented by internal URLs.
      
       Each location can be a region or a zone.
       Only one region or multiple zones in one region is supported now.
       For example,
       ["regions/us-central1"] allow VMs in any zones in region us-central1.
       ["zones/us-central1-a", "zones/us-central1-c"] only allow VMs
       in zones us-central1-a and us-central1-c.
      
       Mixing locations from different regions would cause errors.
       For example,
       ["regions/us-central1", "zones/us-central1-a", "zones/us-central1-b",
       "zones/us-west1-a"] contains locations from two distinct regions:
       us-central1 and us-west1. This combination will trigger an error.
       
      repeated string allowed_locations = 1;
      Specified by:
      getAllowedLocationsCount in interface AllocationPolicy.LocationPolicyOrBuilder
      Returns:
      The count of allowedLocations.
    • getAllowedLocations

      public String getAllowedLocations(int index)
       A list of allowed location names represented by internal URLs.
      
       Each location can be a region or a zone.
       Only one region or multiple zones in one region is supported now.
       For example,
       ["regions/us-central1"] allow VMs in any zones in region us-central1.
       ["zones/us-central1-a", "zones/us-central1-c"] only allow VMs
       in zones us-central1-a and us-central1-c.
      
       Mixing locations from different regions would cause errors.
       For example,
       ["regions/us-central1", "zones/us-central1-a", "zones/us-central1-b",
       "zones/us-west1-a"] contains locations from two distinct regions:
       us-central1 and us-west1. This combination will trigger an error.
       
      repeated string allowed_locations = 1;
      Specified by:
      getAllowedLocations in interface AllocationPolicy.LocationPolicyOrBuilder
      Parameters:
      index - The index of the element to return.
      Returns:
      The allowedLocations at the given index.
    • getAllowedLocationsBytes

      public com.google.protobuf.ByteString getAllowedLocationsBytes(int index)
       A list of allowed location names represented by internal URLs.
      
       Each location can be a region or a zone.
       Only one region or multiple zones in one region is supported now.
       For example,
       ["regions/us-central1"] allow VMs in any zones in region us-central1.
       ["zones/us-central1-a", "zones/us-central1-c"] only allow VMs
       in zones us-central1-a and us-central1-c.
      
       Mixing locations from different regions would cause errors.
       For example,
       ["regions/us-central1", "zones/us-central1-a", "zones/us-central1-b",
       "zones/us-west1-a"] contains locations from two distinct regions:
       us-central1 and us-west1. This combination will trigger an error.
       
      repeated string allowed_locations = 1;
      Specified by:
      getAllowedLocationsBytes in interface AllocationPolicy.LocationPolicyOrBuilder
      Parameters:
      index - The index of the value to return.
      Returns:
      The bytes of the allowedLocations at the given index.
    • getDeniedLocationsList

      public com.google.protobuf.ProtocolStringList getDeniedLocationsList()
       A list of denied location names.
      
       Not yet implemented.
       
      repeated string denied_locations = 2;
      Specified by:
      getDeniedLocationsList in interface AllocationPolicy.LocationPolicyOrBuilder
      Returns:
      A list containing the deniedLocations.
    • getDeniedLocationsCount

      public int getDeniedLocationsCount()
       A list of denied location names.
      
       Not yet implemented.
       
      repeated string denied_locations = 2;
      Specified by:
      getDeniedLocationsCount in interface AllocationPolicy.LocationPolicyOrBuilder
      Returns:
      The count of deniedLocations.
    • getDeniedLocations

      public String getDeniedLocations(int index)
       A list of denied location names.
      
       Not yet implemented.
       
      repeated string denied_locations = 2;
      Specified by:
      getDeniedLocations in interface AllocationPolicy.LocationPolicyOrBuilder
      Parameters:
      index - The index of the element to return.
      Returns:
      The deniedLocations at the given index.
    • getDeniedLocationsBytes

      public com.google.protobuf.ByteString getDeniedLocationsBytes(int index)
       A list of denied location names.
      
       Not yet implemented.
       
      repeated string denied_locations = 2;
      Specified by:
      getDeniedLocationsBytes in interface AllocationPolicy.LocationPolicyOrBuilder
      Parameters:
      index - The index of the value to return.
      Returns:
      The bytes of the deniedLocations at the given index.
    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessage
    • writeTo

      public void writeTo(com.google.protobuf.CodedOutputStream output) throws IOException
      Specified by:
      writeTo in interface com.google.protobuf.MessageLite
      Overrides:
      writeTo in class com.google.protobuf.GeneratedMessage
      Throws:
      IOException
    • getSerializedSize

      public int getSerializedSize()
      Specified by:
      getSerializedSize in interface com.google.protobuf.MessageLite
      Overrides:
      getSerializedSize in class com.google.protobuf.GeneratedMessage
    • equals

      public boolean equals(Object obj)
      Specified by:
      equals in interface com.google.protobuf.Message
      Overrides:
      equals in class com.google.protobuf.AbstractMessage
    • hashCode

      public int hashCode()
      Specified by:
      hashCode in interface com.google.protobuf.Message
      Overrides:
      hashCode in class com.google.protobuf.AbstractMessage
    • parseFrom

      public static AllocationPolicy.LocationPolicy parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static AllocationPolicy.LocationPolicy parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static AllocationPolicy.LocationPolicy parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static AllocationPolicy.LocationPolicy parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static AllocationPolicy.LocationPolicy parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static AllocationPolicy.LocationPolicy parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static AllocationPolicy.LocationPolicy parseFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseFrom

      public static AllocationPolicy.LocationPolicy parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • parseDelimitedFrom

      public static AllocationPolicy.LocationPolicy parseDelimitedFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseDelimitedFrom

      public static AllocationPolicy.LocationPolicy parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • parseFrom

      public static AllocationPolicy.LocationPolicy parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
      Throws:
      IOException
    • parseFrom

      public static AllocationPolicy.LocationPolicy parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • newBuilderForType

      public AllocationPolicy.LocationPolicy.Builder newBuilderForType()
      Specified by:
      newBuilderForType in interface com.google.protobuf.Message
      Specified by:
      newBuilderForType in interface com.google.protobuf.MessageLite
    • newBuilder

      public static AllocationPolicy.LocationPolicy.Builder newBuilder()
    • newBuilder

    • toBuilder

      Specified by:
      toBuilder in interface com.google.protobuf.Message
      Specified by:
      toBuilder in interface com.google.protobuf.MessageLite
    • newBuilderForType

      protected AllocationPolicy.LocationPolicy.Builder newBuilderForType(com.google.protobuf.AbstractMessage.BuilderParent parent)
      Overrides:
      newBuilderForType in class com.google.protobuf.AbstractMessage
    • getDefaultInstance

      public static AllocationPolicy.LocationPolicy getDefaultInstance()
    • parser

      public static com.google.protobuf.Parser<AllocationPolicy.LocationPolicy> parser()
    • getParserForType

      public com.google.protobuf.Parser<AllocationPolicy.LocationPolicy> getParserForType()
      Specified by:
      getParserForType in interface com.google.protobuf.Message
      Specified by:
      getParserForType in interface com.google.protobuf.MessageLite
      Overrides:
      getParserForType in class com.google.protobuf.GeneratedMessage
    • getDefaultInstanceForType

      public AllocationPolicy.LocationPolicy getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder