Class LicenseCode.Builder (1.62.0)

public static final class LicenseCode.Builder extends GeneratedMessageV3.Builder<LicenseCode.Builder> implements LicenseCodeOrBuilder

Represents a License Code resource. A License Code is a unique identifier used to represent a license resource. Caution This resource is intended for use only by third-party partners who are creating Cloud Marketplace images.

Protobuf type google.cloud.compute.v1.LicenseCode

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addAllLicenseAlias(Iterable<? extends LicenseCodeLicenseAlias> values)

public LicenseCode.Builder addAllLicenseAlias(Iterable<? extends LicenseCodeLicenseAlias> values)

[Output Only] URL and description aliases of Licenses with the same License Code.

repeated .google.cloud.compute.v1.LicenseCodeLicenseAlias license_alias = 43550930;

Parameter
Name Description
values Iterable<? extends com.google.cloud.compute.v1.LicenseCodeLicenseAlias>
Returns
Type Description
LicenseCode.Builder

addLicenseAlias(LicenseCodeLicenseAlias value)

public LicenseCode.Builder addLicenseAlias(LicenseCodeLicenseAlias value)

[Output Only] URL and description aliases of Licenses with the same License Code.

repeated .google.cloud.compute.v1.LicenseCodeLicenseAlias license_alias = 43550930;

Parameter
Name Description
value LicenseCodeLicenseAlias
Returns
Type Description
LicenseCode.Builder

addLicenseAlias(LicenseCodeLicenseAlias.Builder builderForValue)

public LicenseCode.Builder addLicenseAlias(LicenseCodeLicenseAlias.Builder builderForValue)

[Output Only] URL and description aliases of Licenses with the same License Code.

repeated .google.cloud.compute.v1.LicenseCodeLicenseAlias license_alias = 43550930;

Parameter
Name Description
builderForValue LicenseCodeLicenseAlias.Builder
Returns
Type Description
LicenseCode.Builder

addLicenseAlias(int index, LicenseCodeLicenseAlias value)

public LicenseCode.Builder addLicenseAlias(int index, LicenseCodeLicenseAlias value)

[Output Only] URL and description aliases of Licenses with the same License Code.

repeated .google.cloud.compute.v1.LicenseCodeLicenseAlias license_alias = 43550930;

Parameters
Name Description
index int
value LicenseCodeLicenseAlias
Returns
Type Description
LicenseCode.Builder

addLicenseAlias(int index, LicenseCodeLicenseAlias.Builder builderForValue)

public LicenseCode.Builder addLicenseAlias(int index, LicenseCodeLicenseAlias.Builder builderForValue)

[Output Only] URL and description aliases of Licenses with the same License Code.

repeated .google.cloud.compute.v1.LicenseCodeLicenseAlias license_alias = 43550930;

Parameters
Name Description
index int
builderForValue LicenseCodeLicenseAlias.Builder
Returns
Type Description
LicenseCode.Builder

addLicenseAliasBuilder()

public LicenseCodeLicenseAlias.Builder addLicenseAliasBuilder()

[Output Only] URL and description aliases of Licenses with the same License Code.

repeated .google.cloud.compute.v1.LicenseCodeLicenseAlias license_alias = 43550930;

Returns
Type Description
LicenseCodeLicenseAlias.Builder

addLicenseAliasBuilder(int index)

public LicenseCodeLicenseAlias.Builder addLicenseAliasBuilder(int index)

[Output Only] URL and description aliases of Licenses with the same License Code.

repeated .google.cloud.compute.v1.LicenseCodeLicenseAlias license_alias = 43550930;

Parameter
Name Description
index int
Returns
Type Description
LicenseCodeLicenseAlias.Builder

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public LicenseCode.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
LicenseCode.Builder
Overrides

build()

public LicenseCode build()
Returns
Type Description
LicenseCode

buildPartial()

public LicenseCode buildPartial()
Returns
Type Description
LicenseCode

clear()

public LicenseCode.Builder clear()
Returns
Type Description
LicenseCode.Builder
Overrides

clearCreationTimestamp()

public LicenseCode.Builder clearCreationTimestamp()

[Output Only] Creation timestamp in RFC3339 text format.

optional string creation_timestamp = 30525366;

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

clearDescription()

public LicenseCode.Builder clearDescription()

[Output Only] Description of this License Code.

optional string description = 422937596;

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public LicenseCode.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
LicenseCode.Builder
Overrides

clearId()

public LicenseCode.Builder clearId()

[Output Only] The unique identifier for the resource. This identifier is defined by the server.

optional uint64 id = 3355;

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

clearKind()

public LicenseCode.Builder clearKind()

[Output Only] Type of resource. Always compute#licenseCode for licenses.

optional string kind = 3292052;

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

clearLicenseAlias()

public LicenseCode.Builder clearLicenseAlias()

[Output Only] URL and description aliases of Licenses with the same License Code.

repeated .google.cloud.compute.v1.LicenseCodeLicenseAlias license_alias = 43550930;

Returns
Type Description
LicenseCode.Builder

clearName()

public LicenseCode.Builder clearName()

[Output Only] Name of the resource. The name is 1-20 characters long and must be a valid 64 bit integer.

optional string name = 3373707;

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public LicenseCode.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
LicenseCode.Builder
Overrides
public LicenseCode.Builder clearSelfLink()

[Output Only] Server-defined URL for the resource.

optional string self_link = 456214797;

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

clearState()

public LicenseCode.Builder clearState()

[Output Only] Current state of this License Code. Check the State enum for the list of possible values.

optional string state = 109757585;

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

clearTransferable()

public LicenseCode.Builder clearTransferable()

[Output Only] If true, the license will remain attached when creating images or snapshots from disks. Otherwise, the license is not transferred.

optional bool transferable = 4349893;

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

clone()

public LicenseCode.Builder clone()
Returns
Type Description
LicenseCode.Builder
Overrides

getCreationTimestamp()

public String getCreationTimestamp()

[Output Only] Creation timestamp in RFC3339 text format.

optional string creation_timestamp = 30525366;

Returns
Type Description
String

The creationTimestamp.

getCreationTimestampBytes()

public ByteString getCreationTimestampBytes()

[Output Only] Creation timestamp in RFC3339 text format.

optional string creation_timestamp = 30525366;

Returns
Type Description
ByteString

The bytes for creationTimestamp.

getDefaultInstanceForType()

public LicenseCode getDefaultInstanceForType()
Returns
Type Description
LicenseCode

getDescription()

public String getDescription()

[Output Only] Description of this License Code.

optional string description = 422937596;

Returns
Type Description
String

The description.

getDescriptionBytes()

public ByteString getDescriptionBytes()

[Output Only] Description of this License Code.

optional string description = 422937596;

Returns
Type Description
ByteString

The bytes for description.

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getId()

public long getId()

[Output Only] The unique identifier for the resource. This identifier is defined by the server.

optional uint64 id = 3355;

Returns
Type Description
long

The id.

getKind()

public String getKind()

[Output Only] Type of resource. Always compute#licenseCode for licenses.

optional string kind = 3292052;

Returns
Type Description
String

The kind.

getKindBytes()

public ByteString getKindBytes()

[Output Only] Type of resource. Always compute#licenseCode for licenses.

optional string kind = 3292052;

Returns
Type Description
ByteString

The bytes for kind.

getLicenseAlias(int index)

public LicenseCodeLicenseAlias getLicenseAlias(int index)

[Output Only] URL and description aliases of Licenses with the same License Code.

repeated .google.cloud.compute.v1.LicenseCodeLicenseAlias license_alias = 43550930;

Parameter
Name Description
index int
Returns
Type Description
LicenseCodeLicenseAlias

getLicenseAliasBuilder(int index)

public LicenseCodeLicenseAlias.Builder getLicenseAliasBuilder(int index)

[Output Only] URL and description aliases of Licenses with the same License Code.

repeated .google.cloud.compute.v1.LicenseCodeLicenseAlias license_alias = 43550930;

Parameter
Name Description
index int
Returns
Type Description
LicenseCodeLicenseAlias.Builder

getLicenseAliasBuilderList()

public List<LicenseCodeLicenseAlias.Builder> getLicenseAliasBuilderList()

[Output Only] URL and description aliases of Licenses with the same License Code.

repeated .google.cloud.compute.v1.LicenseCodeLicenseAlias license_alias = 43550930;

Returns
Type Description
List<Builder>

getLicenseAliasCount()

public int getLicenseAliasCount()

[Output Only] URL and description aliases of Licenses with the same License Code.

repeated .google.cloud.compute.v1.LicenseCodeLicenseAlias license_alias = 43550930;

Returns
Type Description
int

getLicenseAliasList()

public List<LicenseCodeLicenseAlias> getLicenseAliasList()

[Output Only] URL and description aliases of Licenses with the same License Code.

repeated .google.cloud.compute.v1.LicenseCodeLicenseAlias license_alias = 43550930;

Returns
Type Description
List<LicenseCodeLicenseAlias>

getLicenseAliasOrBuilder(int index)

public LicenseCodeLicenseAliasOrBuilder getLicenseAliasOrBuilder(int index)

[Output Only] URL and description aliases of Licenses with the same License Code.

repeated .google.cloud.compute.v1.LicenseCodeLicenseAlias license_alias = 43550930;

Parameter
Name Description
index int
Returns
Type Description
LicenseCodeLicenseAliasOrBuilder

getLicenseAliasOrBuilderList()

public List<? extends LicenseCodeLicenseAliasOrBuilder> getLicenseAliasOrBuilderList()

[Output Only] URL and description aliases of Licenses with the same License Code.

repeated .google.cloud.compute.v1.LicenseCodeLicenseAlias license_alias = 43550930;

Returns
Type Description
List<? extends com.google.cloud.compute.v1.LicenseCodeLicenseAliasOrBuilder>

getName()

public String getName()

[Output Only] Name of the resource. The name is 1-20 characters long and must be a valid 64 bit integer.

optional string name = 3373707;

Returns
Type Description
String

The name.

getNameBytes()

public ByteString getNameBytes()

[Output Only] Name of the resource. The name is 1-20 characters long and must be a valid 64 bit integer.

optional string name = 3373707;

Returns
Type Description
ByteString

The bytes for name.

public String getSelfLink()

[Output Only] Server-defined URL for the resource.

optional string self_link = 456214797;

Returns
Type Description
String

The selfLink.

getSelfLinkBytes()

public ByteString getSelfLinkBytes()

[Output Only] Server-defined URL for the resource.

optional string self_link = 456214797;

Returns
Type Description
ByteString

The bytes for selfLink.

getState()

public String getState()

[Output Only] Current state of this License Code. Check the State enum for the list of possible values.

optional string state = 109757585;

Returns
Type Description
String

The state.

getStateBytes()

public ByteString getStateBytes()

[Output Only] Current state of this License Code. Check the State enum for the list of possible values.

optional string state = 109757585;

Returns
Type Description
ByteString

The bytes for state.

getTransferable()

public boolean getTransferable()

[Output Only] If true, the license will remain attached when creating images or snapshots from disks. Otherwise, the license is not transferred.

optional bool transferable = 4349893;

Returns
Type Description
boolean

The transferable.

hasCreationTimestamp()

public boolean hasCreationTimestamp()

[Output Only] Creation timestamp in RFC3339 text format.

optional string creation_timestamp = 30525366;

Returns
Type Description
boolean

Whether the creationTimestamp field is set.

hasDescription()

public boolean hasDescription()

[Output Only] Description of this License Code.

optional string description = 422937596;

Returns
Type Description
boolean

Whether the description field is set.

hasId()

public boolean hasId()

[Output Only] The unique identifier for the resource. This identifier is defined by the server.

optional uint64 id = 3355;

Returns
Type Description
boolean

Whether the id field is set.

hasKind()

public boolean hasKind()

[Output Only] Type of resource. Always compute#licenseCode for licenses.

optional string kind = 3292052;

Returns
Type Description
boolean

Whether the kind field is set.

hasName()

public boolean hasName()

[Output Only] Name of the resource. The name is 1-20 characters long and must be a valid 64 bit integer.

optional string name = 3373707;

Returns
Type Description
boolean

Whether the name field is set.

public boolean hasSelfLink()

[Output Only] Server-defined URL for the resource.

optional string self_link = 456214797;

Returns
Type Description
boolean

Whether the selfLink field is set.

hasState()

public boolean hasState()

[Output Only] Current state of this License Code. Check the State enum for the list of possible values.

optional string state = 109757585;

Returns
Type Description
boolean

Whether the state field is set.

hasTransferable()

public boolean hasTransferable()

[Output Only] If true, the license will remain attached when creating images or snapshots from disks. Otherwise, the license is not transferred.

optional bool transferable = 4349893;

Returns
Type Description
boolean

Whether the transferable field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(LicenseCode other)

public LicenseCode.Builder mergeFrom(LicenseCode other)
Parameter
Name Description
other LicenseCode
Returns
Type Description
LicenseCode.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public LicenseCode.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
LicenseCode.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public LicenseCode.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
LicenseCode.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final LicenseCode.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
LicenseCode.Builder
Overrides

removeLicenseAlias(int index)

public LicenseCode.Builder removeLicenseAlias(int index)

[Output Only] URL and description aliases of Licenses with the same License Code.

repeated .google.cloud.compute.v1.LicenseCodeLicenseAlias license_alias = 43550930;

Parameter
Name Description
index int
Returns
Type Description
LicenseCode.Builder

setCreationTimestamp(String value)

public LicenseCode.Builder setCreationTimestamp(String value)

[Output Only] Creation timestamp in RFC3339 text format.

optional string creation_timestamp = 30525366;

Parameter
Name Description
value String

The creationTimestamp to set.

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

setCreationTimestampBytes(ByteString value)

public LicenseCode.Builder setCreationTimestampBytes(ByteString value)

[Output Only] Creation timestamp in RFC3339 text format.

optional string creation_timestamp = 30525366;

Parameter
Name Description
value ByteString

The bytes for creationTimestamp to set.

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

setDescription(String value)

public LicenseCode.Builder setDescription(String value)

[Output Only] Description of this License Code.

optional string description = 422937596;

Parameter
Name Description
value String

The description to set.

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

setDescriptionBytes(ByteString value)

public LicenseCode.Builder setDescriptionBytes(ByteString value)

[Output Only] Description of this License Code.

optional string description = 422937596;

Parameter
Name Description
value ByteString

The bytes for description to set.

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

public LicenseCode.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
LicenseCode.Builder
Overrides

setId(long value)

public LicenseCode.Builder setId(long value)

[Output Only] The unique identifier for the resource. This identifier is defined by the server.

optional uint64 id = 3355;

Parameter
Name Description
value long

The id to set.

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

setKind(String value)

public LicenseCode.Builder setKind(String value)

[Output Only] Type of resource. Always compute#licenseCode for licenses.

optional string kind = 3292052;

Parameter
Name Description
value String

The kind to set.

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

setKindBytes(ByteString value)

public LicenseCode.Builder setKindBytes(ByteString value)

[Output Only] Type of resource. Always compute#licenseCode for licenses.

optional string kind = 3292052;

Parameter
Name Description
value ByteString

The bytes for kind to set.

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

setLicenseAlias(int index, LicenseCodeLicenseAlias value)

public LicenseCode.Builder setLicenseAlias(int index, LicenseCodeLicenseAlias value)

[Output Only] URL and description aliases of Licenses with the same License Code.

repeated .google.cloud.compute.v1.LicenseCodeLicenseAlias license_alias = 43550930;

Parameters
Name Description
index int
value LicenseCodeLicenseAlias
Returns
Type Description
LicenseCode.Builder

setLicenseAlias(int index, LicenseCodeLicenseAlias.Builder builderForValue)

public LicenseCode.Builder setLicenseAlias(int index, LicenseCodeLicenseAlias.Builder builderForValue)

[Output Only] URL and description aliases of Licenses with the same License Code.

repeated .google.cloud.compute.v1.LicenseCodeLicenseAlias license_alias = 43550930;

Parameters
Name Description
index int
builderForValue LicenseCodeLicenseAlias.Builder
Returns
Type Description
LicenseCode.Builder

setName(String value)

public LicenseCode.Builder setName(String value)

[Output Only] Name of the resource. The name is 1-20 characters long and must be a valid 64 bit integer.

optional string name = 3373707;

Parameter
Name Description
value String

The name to set.

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

setNameBytes(ByteString value)

public LicenseCode.Builder setNameBytes(ByteString value)

[Output Only] Name of the resource. The name is 1-20 characters long and must be a valid 64 bit integer.

optional string name = 3373707;

Parameter
Name Description
value ByteString

The bytes for name to set.

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

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

public LicenseCode.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
LicenseCode.Builder
Overrides
public LicenseCode.Builder setSelfLink(String value)

[Output Only] Server-defined URL for the resource.

optional string self_link = 456214797;

Parameter
Name Description
value String

The selfLink to set.

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

setSelfLinkBytes(ByteString value)

public LicenseCode.Builder setSelfLinkBytes(ByteString value)

[Output Only] Server-defined URL for the resource.

optional string self_link = 456214797;

Parameter
Name Description
value ByteString

The bytes for selfLink to set.

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

setState(String value)

public LicenseCode.Builder setState(String value)

[Output Only] Current state of this License Code. Check the State enum for the list of possible values.

optional string state = 109757585;

Parameter
Name Description
value String

The state to set.

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

setStateBytes(ByteString value)

public LicenseCode.Builder setStateBytes(ByteString value)

[Output Only] Current state of this License Code. Check the State enum for the list of possible values.

optional string state = 109757585;

Parameter
Name Description
value ByteString

The bytes for state to set.

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

setTransferable(boolean value)

public LicenseCode.Builder setTransferable(boolean value)

[Output Only] If true, the license will remain attached when creating images or snapshots from disks. Otherwise, the license is not transferred.

optional bool transferable = 4349893;

Parameter
Name Description
value boolean

The transferable to set.

Returns
Type Description
LicenseCode.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

public final LicenseCode.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
LicenseCode.Builder
Overrides