Class Sku.Builder (3.5.1)

public static final class Sku.Builder extends GeneratedMessageV3.Builder<Sku.Builder> implements SkuOrBuilder

Represents a product's purchasable Stock Keeping Unit (SKU). SKUs represent the different variations of the product. For example, Google Workspace Business Standard and Google Workspace Business Plus are Google Workspace product SKUs.

Protobuf type google.cloud.channel.v1.Sku

Implements

SkuOrBuilder

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public Sku.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
Sku.Builder
Overrides

build()

public Sku build()
Returns
TypeDescription
Sku

buildPartial()

public Sku buildPartial()
Returns
TypeDescription
Sku

clear()

public Sku.Builder clear()
Returns
TypeDescription
Sku.Builder
Overrides

clearField(Descriptors.FieldDescriptor field)

public Sku.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
Sku.Builder
Overrides

clearMarketingInfo()

public Sku.Builder clearMarketingInfo()

Marketing information for the SKU.

.google.cloud.channel.v1.MarketingInfo marketing_info = 2;

Returns
TypeDescription
Sku.Builder

clearName()

public Sku.Builder clearName()

Resource Name of the SKU. Format: products/{product_id}/skus/{sku_id}

string name = 1;

Returns
TypeDescription
Sku.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public Sku.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
Sku.Builder
Overrides

clearProduct()

public Sku.Builder clearProduct()

Product the SKU is associated with.

.google.cloud.channel.v1.Product product = 3;

Returns
TypeDescription
Sku.Builder

clone()

public Sku.Builder clone()
Returns
TypeDescription
Sku.Builder
Overrides

getDefaultInstanceForType()

public Sku getDefaultInstanceForType()
Returns
TypeDescription
Sku

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getMarketingInfo()

public MarketingInfo getMarketingInfo()

Marketing information for the SKU.

.google.cloud.channel.v1.MarketingInfo marketing_info = 2;

Returns
TypeDescription
MarketingInfo

The marketingInfo.

getMarketingInfoBuilder()

public MarketingInfo.Builder getMarketingInfoBuilder()

Marketing information for the SKU.

.google.cloud.channel.v1.MarketingInfo marketing_info = 2;

Returns
TypeDescription
MarketingInfo.Builder

getMarketingInfoOrBuilder()

public MarketingInfoOrBuilder getMarketingInfoOrBuilder()

Marketing information for the SKU.

.google.cloud.channel.v1.MarketingInfo marketing_info = 2;

Returns
TypeDescription
MarketingInfoOrBuilder

getName()

public String getName()

Resource Name of the SKU. Format: products/{product_id}/skus/{sku_id}

string name = 1;

Returns
TypeDescription
String

The name.

getNameBytes()

public ByteString getNameBytes()

Resource Name of the SKU. Format: products/{product_id}/skus/{sku_id}

string name = 1;

Returns
TypeDescription
ByteString

The bytes for name.

getProduct()

public Product getProduct()

Product the SKU is associated with.

.google.cloud.channel.v1.Product product = 3;

Returns
TypeDescription
Product

The product.

getProductBuilder()

public Product.Builder getProductBuilder()

Product the SKU is associated with.

.google.cloud.channel.v1.Product product = 3;

Returns
TypeDescription
Product.Builder

getProductOrBuilder()

public ProductOrBuilder getProductOrBuilder()

Product the SKU is associated with.

.google.cloud.channel.v1.Product product = 3;

Returns
TypeDescription
ProductOrBuilder

hasMarketingInfo()

public boolean hasMarketingInfo()

Marketing information for the SKU.

.google.cloud.channel.v1.MarketingInfo marketing_info = 2;

Returns
TypeDescription
boolean

Whether the marketingInfo field is set.

hasProduct()

public boolean hasProduct()

Product the SKU is associated with.

.google.cloud.channel.v1.Product product = 3;

Returns
TypeDescription
boolean

Whether the product field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(Sku other)

public Sku.Builder mergeFrom(Sku other)
Parameter
NameDescription
otherSku
Returns
TypeDescription
Sku.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public Sku.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Sku.Builder
Overrides Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public Sku.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
Sku.Builder
Overrides

mergeMarketingInfo(MarketingInfo value)

public Sku.Builder mergeMarketingInfo(MarketingInfo value)

Marketing information for the SKU.

.google.cloud.channel.v1.MarketingInfo marketing_info = 2;

Parameter
NameDescription
valueMarketingInfo
Returns
TypeDescription
Sku.Builder

mergeProduct(Product value)

public Sku.Builder mergeProduct(Product value)

Product the SKU is associated with.

.google.cloud.channel.v1.Product product = 3;

Parameter
NameDescription
valueProduct
Returns
TypeDescription
Sku.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

public final Sku.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
Sku.Builder
Overrides

setField(Descriptors.FieldDescriptor field, Object value)

public Sku.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
Sku.Builder
Overrides

setMarketingInfo(MarketingInfo value)

public Sku.Builder setMarketingInfo(MarketingInfo value)

Marketing information for the SKU.

.google.cloud.channel.v1.MarketingInfo marketing_info = 2;

Parameter
NameDescription
valueMarketingInfo
Returns
TypeDescription
Sku.Builder

setMarketingInfo(MarketingInfo.Builder builderForValue)

public Sku.Builder setMarketingInfo(MarketingInfo.Builder builderForValue)

Marketing information for the SKU.

.google.cloud.channel.v1.MarketingInfo marketing_info = 2;

Parameter
NameDescription
builderForValueMarketingInfo.Builder
Returns
TypeDescription
Sku.Builder

setName(String value)

public Sku.Builder setName(String value)

Resource Name of the SKU. Format: products/{product_id}/skus/{sku_id}

string name = 1;

Parameter
NameDescription
valueString

The name to set.

Returns
TypeDescription
Sku.Builder

This builder for chaining.

setNameBytes(ByteString value)

public Sku.Builder setNameBytes(ByteString value)

Resource Name of the SKU. Format: products/{product_id}/skus/{sku_id}

string name = 1;

Parameter
NameDescription
valueByteString

The bytes for name to set.

Returns
TypeDescription
Sku.Builder

This builder for chaining.

setProduct(Product value)

public Sku.Builder setProduct(Product value)

Product the SKU is associated with.

.google.cloud.channel.v1.Product product = 3;

Parameter
NameDescription
valueProduct
Returns
TypeDescription
Sku.Builder

setProduct(Product.Builder builderForValue)

public Sku.Builder setProduct(Product.Builder builderForValue)

Product the SKU is associated with.

.google.cloud.channel.v1.Product product = 3;

Parameter
NameDescription
builderForValueProduct.Builder
Returns
TypeDescription
Sku.Builder

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public Sku.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
Sku.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final Sku.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
Sku.Builder
Overrides