Class Asset.Builder (0.37.0)

public static final class Asset.Builder extends GeneratedMessageV3.Builder<Asset.Builder> implements AssetOrBuilder

An asset represents a video or an image.

Protobuf type google.cloud.video.livestream.v1.Asset

Implements

AssetOrBuilder

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public Asset build()
Returns
TypeDescription
Asset

buildPartial()

public Asset buildPartial()
Returns
TypeDescription
Asset

clear()

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

clearCrc32C()

public Asset.Builder clearCrc32C()

Based64-encoded CRC32c checksum of the asset file. For more information, see the crc32c checksum of the Cloud Storage Objects resource. If crc32c is omitted or left empty when the asset is created, this field is filled by the crc32c checksum of the Cloud Storage object indicated by [VideoAsset.uri] or [ImageAsset.uri]. If crc32c is set, the asset can't be created if the crc32c value does not match with the crc32c checksum of the Cloud Storage object indicated by [VideoAsset.uri] or [ImageAsset.uri].

string crc32c = 7;

Returns
TypeDescription
Asset.Builder

This builder for chaining.

clearCreateTime()

public Asset.Builder clearCreateTime()

Output only. The creation time.

.google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
Asset.Builder

clearError()

public Asset.Builder clearError()

Output only. Only present when state is ERROR. The reason for the error state of the asset.

.google.rpc.Status error = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
Asset.Builder

clearField(Descriptors.FieldDescriptor field)

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

clearImage()

public Asset.Builder clearImage()

ImageAsset represents an image.

.google.cloud.video.livestream.v1.Asset.ImageAsset image = 6;

Returns
TypeDescription
Asset.Builder

clearLabels()

public Asset.Builder clearLabels()
Returns
TypeDescription
Asset.Builder

clearName()

public Asset.Builder clearName()

The resource name of the asset, in the form of: projects/{project}/locations/{location}/assets/{assetId}.

string name = 1;

Returns
TypeDescription
Asset.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

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

clearResource()

public Asset.Builder clearResource()
Returns
TypeDescription
Asset.Builder

clearState()

public Asset.Builder clearState()

Output only. The state of the asset resource.

.google.cloud.video.livestream.v1.Asset.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
Asset.Builder

This builder for chaining.

clearUpdateTime()

public Asset.Builder clearUpdateTime()

Output only. The update time.

.google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
Asset.Builder

clearVideo()

public Asset.Builder clearVideo()

VideoAsset represents a video.

.google.cloud.video.livestream.v1.Asset.VideoAsset video = 5;

Returns
TypeDescription
Asset.Builder

clone()

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

containsLabels(String key)

public boolean containsLabels(String key)

User-defined key/value metadata.

map<string, string> labels = 4;

Parameter
NameDescription
keyString
Returns
TypeDescription
boolean

getCrc32C()

public String getCrc32C()

Based64-encoded CRC32c checksum of the asset file. For more information, see the crc32c checksum of the Cloud Storage Objects resource. If crc32c is omitted or left empty when the asset is created, this field is filled by the crc32c checksum of the Cloud Storage object indicated by [VideoAsset.uri] or [ImageAsset.uri]. If crc32c is set, the asset can't be created if the crc32c value does not match with the crc32c checksum of the Cloud Storage object indicated by [VideoAsset.uri] or [ImageAsset.uri].

string crc32c = 7;

Returns
TypeDescription
String

The crc32c.

getCrc32CBytes()

public ByteString getCrc32CBytes()

Based64-encoded CRC32c checksum of the asset file. For more information, see the crc32c checksum of the Cloud Storage Objects resource. If crc32c is omitted or left empty when the asset is created, this field is filled by the crc32c checksum of the Cloud Storage object indicated by [VideoAsset.uri] or [ImageAsset.uri]. If crc32c is set, the asset can't be created if the crc32c value does not match with the crc32c checksum of the Cloud Storage object indicated by [VideoAsset.uri] or [ImageAsset.uri].

string crc32c = 7;

Returns
TypeDescription
ByteString

The bytes for crc32c.

getCreateTime()

public Timestamp getCreateTime()

Output only. The creation time.

.google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
Timestamp

The createTime.

getCreateTimeBuilder()

public Timestamp.Builder getCreateTimeBuilder()

Output only. The creation time.

.google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
Builder

getCreateTimeOrBuilder()

public TimestampOrBuilder getCreateTimeOrBuilder()

Output only. The creation time.

.google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
TimestampOrBuilder

getDefaultInstanceForType()

public Asset getDefaultInstanceForType()
Returns
TypeDescription
Asset

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getError()

public Status getError()

Output only. Only present when state is ERROR. The reason for the error state of the asset.

.google.rpc.Status error = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
com.google.rpc.Status

The error.

getErrorBuilder()

public Status.Builder getErrorBuilder()

Output only. Only present when state is ERROR. The reason for the error state of the asset.

.google.rpc.Status error = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
com.google.rpc.Status.Builder

getErrorOrBuilder()

public StatusOrBuilder getErrorOrBuilder()

Output only. Only present when state is ERROR. The reason for the error state of the asset.

.google.rpc.Status error = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
com.google.rpc.StatusOrBuilder

getImage()

public Asset.ImageAsset getImage()

ImageAsset represents an image.

.google.cloud.video.livestream.v1.Asset.ImageAsset image = 6;

Returns
TypeDescription
Asset.ImageAsset

The image.

getImageBuilder()

public Asset.ImageAsset.Builder getImageBuilder()

ImageAsset represents an image.

.google.cloud.video.livestream.v1.Asset.ImageAsset image = 6;

Returns
TypeDescription
Asset.ImageAsset.Builder

getImageOrBuilder()

public Asset.ImageAssetOrBuilder getImageOrBuilder()

ImageAsset represents an image.

.google.cloud.video.livestream.v1.Asset.ImageAsset image = 6;

Returns
TypeDescription
Asset.ImageAssetOrBuilder

getLabels() (deprecated)

public Map<String,String> getLabels()

Use #getLabelsMap() instead.

Returns
TypeDescription
Map<String,String>

getLabelsCount()

public int getLabelsCount()

User-defined key/value metadata.

map<string, string> labels = 4;

Returns
TypeDescription
int

getLabelsMap()

public Map<String,String> getLabelsMap()

User-defined key/value metadata.

map<string, string> labels = 4;

Returns
TypeDescription
Map<String,String>

getLabelsOrDefault(String key, String defaultValue)

public String getLabelsOrDefault(String key, String defaultValue)

User-defined key/value metadata.

map<string, string> labels = 4;

Parameters
NameDescription
keyString
defaultValueString
Returns
TypeDescription
String

getLabelsOrThrow(String key)

public String getLabelsOrThrow(String key)

User-defined key/value metadata.

map<string, string> labels = 4;

Parameter
NameDescription
keyString
Returns
TypeDescription
String

getMutableLabels() (deprecated)

public Map<String,String> getMutableLabels()

Use alternate mutation accessors instead.

Returns
TypeDescription
Map<String,String>

getName()

public String getName()

The resource name of the asset, in the form of: projects/{project}/locations/{location}/assets/{assetId}.

string name = 1;

Returns
TypeDescription
String

The name.

getNameBytes()

public ByteString getNameBytes()

The resource name of the asset, in the form of: projects/{project}/locations/{location}/assets/{assetId}.

string name = 1;

Returns
TypeDescription
ByteString

The bytes for name.

getResourceCase()

public Asset.ResourceCase getResourceCase()
Returns
TypeDescription
Asset.ResourceCase

getState()

public Asset.State getState()

Output only. The state of the asset resource.

.google.cloud.video.livestream.v1.Asset.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
Asset.State

The state.

getStateValue()

public int getStateValue()

Output only. The state of the asset resource.

.google.cloud.video.livestream.v1.Asset.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
int

The enum numeric value on the wire for state.

getUpdateTime()

public Timestamp getUpdateTime()

Output only. The update time.

.google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
Timestamp

The updateTime.

getUpdateTimeBuilder()

public Timestamp.Builder getUpdateTimeBuilder()

Output only. The update time.

.google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
Builder

getUpdateTimeOrBuilder()

public TimestampOrBuilder getUpdateTimeOrBuilder()

Output only. The update time.

.google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
TimestampOrBuilder

getVideo()

public Asset.VideoAsset getVideo()

VideoAsset represents a video.

.google.cloud.video.livestream.v1.Asset.VideoAsset video = 5;

Returns
TypeDescription
Asset.VideoAsset

The video.

getVideoBuilder()

public Asset.VideoAsset.Builder getVideoBuilder()

VideoAsset represents a video.

.google.cloud.video.livestream.v1.Asset.VideoAsset video = 5;

Returns
TypeDescription
Asset.VideoAsset.Builder

getVideoOrBuilder()

public Asset.VideoAssetOrBuilder getVideoOrBuilder()

VideoAsset represents a video.

.google.cloud.video.livestream.v1.Asset.VideoAsset video = 5;

Returns
TypeDescription
Asset.VideoAssetOrBuilder

hasCreateTime()

public boolean hasCreateTime()

Output only. The creation time.

.google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
boolean

Whether the createTime field is set.

hasError()

public boolean hasError()

Output only. Only present when state is ERROR. The reason for the error state of the asset.

.google.rpc.Status error = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
boolean

Whether the error field is set.

hasImage()

public boolean hasImage()

ImageAsset represents an image.

.google.cloud.video.livestream.v1.Asset.ImageAsset image = 6;

Returns
TypeDescription
boolean

Whether the image field is set.

hasUpdateTime()

public boolean hasUpdateTime()

Output only. The update time.

.google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
boolean

Whether the updateTime field is set.

hasVideo()

public boolean hasVideo()

VideoAsset represents a video.

.google.cloud.video.livestream.v1.Asset.VideoAsset video = 5;

Returns
TypeDescription
boolean

Whether the video field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

internalGetMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
Parameter
NameDescription
numberint
Returns
TypeDescription
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMapFieldReflection(int)

internalGetMutableMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMutableMapFieldReflection(int number)
Parameter
NameDescription
numberint
Returns
TypeDescription
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMutableMapFieldReflection(int)

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeCreateTime(Timestamp value)

public Asset.Builder mergeCreateTime(Timestamp value)

Output only. The creation time.

.google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
valueTimestamp
Returns
TypeDescription
Asset.Builder

mergeError(Status value)

public Asset.Builder mergeError(Status value)

Output only. Only present when state is ERROR. The reason for the error state of the asset.

.google.rpc.Status error = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
valuecom.google.rpc.Status
Returns
TypeDescription
Asset.Builder

mergeFrom(Asset other)

public Asset.Builder mergeFrom(Asset other)
Parameter
NameDescription
otherAsset
Returns
TypeDescription
Asset.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeImage(Asset.ImageAsset value)

public Asset.Builder mergeImage(Asset.ImageAsset value)

ImageAsset represents an image.

.google.cloud.video.livestream.v1.Asset.ImageAsset image = 6;

Parameter
NameDescription
valueAsset.ImageAsset
Returns
TypeDescription
Asset.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

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

mergeUpdateTime(Timestamp value)

public Asset.Builder mergeUpdateTime(Timestamp value)

Output only. The update time.

.google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
valueTimestamp
Returns
TypeDescription
Asset.Builder

mergeVideo(Asset.VideoAsset value)

public Asset.Builder mergeVideo(Asset.VideoAsset value)

VideoAsset represents a video.

.google.cloud.video.livestream.v1.Asset.VideoAsset video = 5;

Parameter
NameDescription
valueAsset.VideoAsset
Returns
TypeDescription
Asset.Builder

putAllLabels(Map<String,String> values)

public Asset.Builder putAllLabels(Map<String,String> values)

User-defined key/value metadata.

map<string, string> labels = 4;

Parameter
NameDescription
valuesMap<String,String>
Returns
TypeDescription
Asset.Builder

putLabels(String key, String value)

public Asset.Builder putLabels(String key, String value)

User-defined key/value metadata.

map<string, string> labels = 4;

Parameters
NameDescription
keyString
valueString
Returns
TypeDescription
Asset.Builder

removeLabels(String key)

public Asset.Builder removeLabels(String key)

User-defined key/value metadata.

map<string, string> labels = 4;

Parameter
NameDescription
keyString
Returns
TypeDescription
Asset.Builder

setCrc32C(String value)

public Asset.Builder setCrc32C(String value)

Based64-encoded CRC32c checksum of the asset file. For more information, see the crc32c checksum of the Cloud Storage Objects resource. If crc32c is omitted or left empty when the asset is created, this field is filled by the crc32c checksum of the Cloud Storage object indicated by [VideoAsset.uri] or [ImageAsset.uri]. If crc32c is set, the asset can't be created if the crc32c value does not match with the crc32c checksum of the Cloud Storage object indicated by [VideoAsset.uri] or [ImageAsset.uri].

string crc32c = 7;

Parameter
NameDescription
valueString

The crc32c to set.

Returns
TypeDescription
Asset.Builder

This builder for chaining.

setCrc32CBytes(ByteString value)

public Asset.Builder setCrc32CBytes(ByteString value)

Based64-encoded CRC32c checksum of the asset file. For more information, see the crc32c checksum of the Cloud Storage Objects resource. If crc32c is omitted or left empty when the asset is created, this field is filled by the crc32c checksum of the Cloud Storage object indicated by [VideoAsset.uri] or [ImageAsset.uri]. If crc32c is set, the asset can't be created if the crc32c value does not match with the crc32c checksum of the Cloud Storage object indicated by [VideoAsset.uri] or [ImageAsset.uri].

string crc32c = 7;

Parameter
NameDescription
valueByteString

The bytes for crc32c to set.

Returns
TypeDescription
Asset.Builder

This builder for chaining.

setCreateTime(Timestamp value)

public Asset.Builder setCreateTime(Timestamp value)

Output only. The creation time.

.google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
valueTimestamp
Returns
TypeDescription
Asset.Builder

setCreateTime(Timestamp.Builder builderForValue)

public Asset.Builder setCreateTime(Timestamp.Builder builderForValue)

Output only. The creation time.

.google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
builderForValueBuilder
Returns
TypeDescription
Asset.Builder

setError(Status value)

public Asset.Builder setError(Status value)

Output only. Only present when state is ERROR. The reason for the error state of the asset.

.google.rpc.Status error = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
valuecom.google.rpc.Status
Returns
TypeDescription
Asset.Builder

setError(Status.Builder builderForValue)

public Asset.Builder setError(Status.Builder builderForValue)

Output only. Only present when state is ERROR. The reason for the error state of the asset.

.google.rpc.Status error = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
builderForValuecom.google.rpc.Status.Builder
Returns
TypeDescription
Asset.Builder

setField(Descriptors.FieldDescriptor field, Object value)

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

setImage(Asset.ImageAsset value)

public Asset.Builder setImage(Asset.ImageAsset value)

ImageAsset represents an image.

.google.cloud.video.livestream.v1.Asset.ImageAsset image = 6;

Parameter
NameDescription
valueAsset.ImageAsset
Returns
TypeDescription
Asset.Builder

setImage(Asset.ImageAsset.Builder builderForValue)

public Asset.Builder setImage(Asset.ImageAsset.Builder builderForValue)

ImageAsset represents an image.

.google.cloud.video.livestream.v1.Asset.ImageAsset image = 6;

Parameter
NameDescription
builderForValueAsset.ImageAsset.Builder
Returns
TypeDescription
Asset.Builder

setName(String value)

public Asset.Builder setName(String value)

The resource name of the asset, in the form of: projects/{project}/locations/{location}/assets/{assetId}.

string name = 1;

Parameter
NameDescription
valueString

The name to set.

Returns
TypeDescription
Asset.Builder

This builder for chaining.

setNameBytes(ByteString value)

public Asset.Builder setNameBytes(ByteString value)

The resource name of the asset, in the form of: projects/{project}/locations/{location}/assets/{assetId}.

string name = 1;

Parameter
NameDescription
valueByteString

The bytes for name to set.

Returns
TypeDescription
Asset.Builder

This builder for chaining.

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

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

setState(Asset.State value)

public Asset.Builder setState(Asset.State value)

Output only. The state of the asset resource.

.google.cloud.video.livestream.v1.Asset.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
valueAsset.State

The state to set.

Returns
TypeDescription
Asset.Builder

This builder for chaining.

setStateValue(int value)

public Asset.Builder setStateValue(int value)

Output only. The state of the asset resource.

.google.cloud.video.livestream.v1.Asset.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
valueint

The enum numeric value on the wire for state to set.

Returns
TypeDescription
Asset.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

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

setUpdateTime(Timestamp value)

public Asset.Builder setUpdateTime(Timestamp value)

Output only. The update time.

.google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
valueTimestamp
Returns
TypeDescription
Asset.Builder

setUpdateTime(Timestamp.Builder builderForValue)

public Asset.Builder setUpdateTime(Timestamp.Builder builderForValue)

Output only. The update time.

.google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
builderForValueBuilder
Returns
TypeDescription
Asset.Builder

setVideo(Asset.VideoAsset value)

public Asset.Builder setVideo(Asset.VideoAsset value)

VideoAsset represents a video.

.google.cloud.video.livestream.v1.Asset.VideoAsset video = 5;

Parameter
NameDescription
valueAsset.VideoAsset
Returns
TypeDescription
Asset.Builder

setVideo(Asset.VideoAsset.Builder builderForValue)

public Asset.Builder setVideo(Asset.VideoAsset.Builder builderForValue)

VideoAsset represents a video.

.google.cloud.video.livestream.v1.Asset.VideoAsset video = 5;

Parameter
NameDescription
builderForValueAsset.VideoAsset.Builder
Returns
TypeDescription
Asset.Builder