Class CustomerConstraints (3.32.0)

public final class CustomerConstraints extends GeneratedMessageV3 implements CustomerConstraintsOrBuilder

Represents constraints required to purchase the Offer for a customer.

Protobuf type google.cloud.channel.v1.CustomerConstraints

Static Fields

ALLOWED_CUSTOMER_TYPES_FIELD_NUMBER

public static final int ALLOWED_CUSTOMER_TYPES_FIELD_NUMBER
Field Value
TypeDescription
int

ALLOWED_REGIONS_FIELD_NUMBER

public static final int ALLOWED_REGIONS_FIELD_NUMBER
Field Value
TypeDescription
int

PROMOTIONAL_ORDER_TYPES_FIELD_NUMBER

public static final int PROMOTIONAL_ORDER_TYPES_FIELD_NUMBER
Field Value
TypeDescription
int

Static Methods

getDefaultInstance()

public static CustomerConstraints getDefaultInstance()
Returns
TypeDescription
CustomerConstraints

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

newBuilder()

public static CustomerConstraints.Builder newBuilder()
Returns
TypeDescription
CustomerConstraints.Builder

newBuilder(CustomerConstraints prototype)

public static CustomerConstraints.Builder newBuilder(CustomerConstraints prototype)
Parameter
NameDescription
prototypeCustomerConstraints
Returns
TypeDescription
CustomerConstraints.Builder

parseDelimitedFrom(InputStream input)

public static CustomerConstraints parseDelimitedFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
CustomerConstraints
Exceptions
TypeDescription
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static CustomerConstraints parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
CustomerConstraints
Exceptions
TypeDescription
IOException

parseFrom(byte[] data)

public static CustomerConstraints parseFrom(byte[] data)
Parameter
NameDescription
databyte[]
Returns
TypeDescription
CustomerConstraints
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static CustomerConstraints parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
databyte[]
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
CustomerConstraints
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data)

public static CustomerConstraints parseFrom(ByteString data)
Parameter
NameDescription
dataByteString
Returns
TypeDescription
CustomerConstraints
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static CustomerConstraints parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteString
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
CustomerConstraints
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static CustomerConstraints parseFrom(CodedInputStream input)
Parameter
NameDescription
inputCodedInputStream
Returns
TypeDescription
CustomerConstraints
Exceptions
TypeDescription
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static CustomerConstraints parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
CustomerConstraints
Exceptions
TypeDescription
IOException

parseFrom(InputStream input)

public static CustomerConstraints parseFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
CustomerConstraints
Exceptions
TypeDescription
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static CustomerConstraints parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
CustomerConstraints
Exceptions
TypeDescription
IOException

parseFrom(ByteBuffer data)

public static CustomerConstraints parseFrom(ByteBuffer data)
Parameter
NameDescription
dataByteBuffer
Returns
TypeDescription
CustomerConstraints
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static CustomerConstraints parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteBuffer
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
CustomerConstraints
Exceptions
TypeDescription
InvalidProtocolBufferException

parser()

public static Parser<CustomerConstraints> parser()
Returns
TypeDescription
Parser<CustomerConstraints>

Methods

equals(Object obj)

public boolean equals(Object obj)
Parameter
NameDescription
objObject
Returns
TypeDescription
boolean
Overrides

getAllowedCustomerTypes(int index)

public CloudIdentityInfo.CustomerType getAllowedCustomerTypes(int index)

Allowed Customer Type.

repeated .google.cloud.channel.v1.CloudIdentityInfo.CustomerType allowed_customer_types = 2;

Parameter
NameDescription
indexint

The index of the element to return.

Returns
TypeDescription
CloudIdentityInfo.CustomerType

The allowedCustomerTypes at the given index.

getAllowedCustomerTypesCount()

public int getAllowedCustomerTypesCount()

Allowed Customer Type.

repeated .google.cloud.channel.v1.CloudIdentityInfo.CustomerType allowed_customer_types = 2;

Returns
TypeDescription
int

The count of allowedCustomerTypes.

getAllowedCustomerTypesList()

public List<CloudIdentityInfo.CustomerType> getAllowedCustomerTypesList()

Allowed Customer Type.

repeated .google.cloud.channel.v1.CloudIdentityInfo.CustomerType allowed_customer_types = 2;

Returns
TypeDescription
List<CustomerType>

A list containing the allowedCustomerTypes.

getAllowedCustomerTypesValue(int index)

public int getAllowedCustomerTypesValue(int index)

Allowed Customer Type.

repeated .google.cloud.channel.v1.CloudIdentityInfo.CustomerType allowed_customer_types = 2;

Parameter
NameDescription
indexint

The index of the value to return.

Returns
TypeDescription
int

The enum numeric value on the wire of allowedCustomerTypes at the given index.

getAllowedCustomerTypesValueList()

public List<Integer> getAllowedCustomerTypesValueList()

Allowed Customer Type.

repeated .google.cloud.channel.v1.CloudIdentityInfo.CustomerType allowed_customer_types = 2;

Returns
TypeDescription
List<Integer>

A list containing the enum numeric values on the wire for allowedCustomerTypes.

getAllowedRegions(int index)

public String getAllowedRegions(int index)

Allowed geographical regions of the customer.

repeated string allowed_regions = 1;

Parameter
NameDescription
indexint

The index of the element to return.

Returns
TypeDescription
String

The allowedRegions at the given index.

getAllowedRegionsBytes(int index)

public ByteString getAllowedRegionsBytes(int index)

Allowed geographical regions of the customer.

repeated string allowed_regions = 1;

Parameter
NameDescription
indexint

The index of the value to return.

Returns
TypeDescription
ByteString

The bytes of the allowedRegions at the given index.

getAllowedRegionsCount()

public int getAllowedRegionsCount()

Allowed geographical regions of the customer.

repeated string allowed_regions = 1;

Returns
TypeDescription
int

The count of allowedRegions.

getAllowedRegionsList()

public ProtocolStringList getAllowedRegionsList()

Allowed geographical regions of the customer.

repeated string allowed_regions = 1;

Returns
TypeDescription
ProtocolStringList

A list containing the allowedRegions.

getDefaultInstanceForType()

public CustomerConstraints getDefaultInstanceForType()
Returns
TypeDescription
CustomerConstraints

getParserForType()

public Parser<CustomerConstraints> getParserForType()
Returns
TypeDescription
Parser<CustomerConstraints>
Overrides

getPromotionalOrderTypes(int index)

public PromotionalOrderType getPromotionalOrderTypes(int index)

Allowed Promotional Order Type. Present for Promotional offers.

repeated .google.cloud.channel.v1.PromotionalOrderType promotional_order_types = 3;

Parameter
NameDescription
indexint

The index of the element to return.

Returns
TypeDescription
PromotionalOrderType

The promotionalOrderTypes at the given index.

getPromotionalOrderTypesCount()

public int getPromotionalOrderTypesCount()

Allowed Promotional Order Type. Present for Promotional offers.

repeated .google.cloud.channel.v1.PromotionalOrderType promotional_order_types = 3;

Returns
TypeDescription
int

The count of promotionalOrderTypes.

getPromotionalOrderTypesList()

public List<PromotionalOrderType> getPromotionalOrderTypesList()

Allowed Promotional Order Type. Present for Promotional offers.

repeated .google.cloud.channel.v1.PromotionalOrderType promotional_order_types = 3;

Returns
TypeDescription
List<PromotionalOrderType>

A list containing the promotionalOrderTypes.

getPromotionalOrderTypesValue(int index)

public int getPromotionalOrderTypesValue(int index)

Allowed Promotional Order Type. Present for Promotional offers.

repeated .google.cloud.channel.v1.PromotionalOrderType promotional_order_types = 3;

Parameter
NameDescription
indexint

The index of the value to return.

Returns
TypeDescription
int

The enum numeric value on the wire of promotionalOrderTypes at the given index.

getPromotionalOrderTypesValueList()

public List<Integer> getPromotionalOrderTypesValueList()

Allowed Promotional Order Type. Present for Promotional offers.

repeated .google.cloud.channel.v1.PromotionalOrderType promotional_order_types = 3;

Returns
TypeDescription
List<Integer>

A list containing the enum numeric values on the wire for promotionalOrderTypes.

getSerializedSize()

public int getSerializedSize()
Returns
TypeDescription
int
Overrides

hashCode()

public int hashCode()
Returns
TypeDescription
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

newBuilderForType()

public CustomerConstraints.Builder newBuilderForType()
Returns
TypeDescription
CustomerConstraints.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected CustomerConstraints.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
NameDescription
parentBuilderParent
Returns
TypeDescription
CustomerConstraints.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
NameDescription
unusedUnusedPrivateParameter
Returns
TypeDescription
Object
Overrides

toBuilder()

public CustomerConstraints.Builder toBuilder()
Returns
TypeDescription
CustomerConstraints.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
NameDescription
outputCodedOutputStream
Overrides
Exceptions
TypeDescription
IOException