Class Asset.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<Asset.Builder>
com.google.cloud.visionai.v1.Asset.Builder
All Implemented Interfaces:
AssetOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
Asset

public static final class Asset.Builder extends com.google.protobuf.GeneratedMessage.Builder<Asset.Builder> implements AssetOrBuilder
 An asset is a resource in corpus. It represents a media object inside corpus,
 contains metadata and another resource annotation. Different feature could be
 applied to the asset to generate annotations. User could specified annotation
 related to the target asset.
 
Protobuf type google.cloud.visionai.v1.Asset
  • Method Summary

    Modifier and Type
    Method
    Description
     
     
     
    Output only.
    Resource name of the asset.
    The duration for which all media assets, associated metadata, and search documents can exist.
    Output only.
    Output only.
    Output only.
     
    static final com.google.protobuf.Descriptors.Descriptor
     
    com.google.protobuf.Descriptors.Descriptor
     
    Resource name of the asset.
    com.google.protobuf.ByteString
    Resource name of the asset.
    com.google.protobuf.Duration
    The duration for which all media assets, associated metadata, and search documents can exist.
    com.google.protobuf.Duration.Builder
    The duration for which all media assets, associated metadata, and search documents can exist.
    com.google.protobuf.DurationOrBuilder
    The duration for which all media assets, associated metadata, and search documents can exist.
    boolean
    Output only.
    boolean
    The duration for which all media assets, associated metadata, and search documents can exist.
    protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
     
    final boolean
     
    Output only.
     
    mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
     
    mergeFrom(com.google.protobuf.Message other)
     
    mergeTtl(com.google.protobuf.Duration value)
    The duration for which all media assets, associated metadata, and search documents can exist.
    Output only.
    Output only.
    setName(String value)
    Resource name of the asset.
    setNameBytes(com.google.protobuf.ByteString value)
    Resource name of the asset.
    setTtl(com.google.protobuf.Duration value)
    The duration for which all media assets, associated metadata, and search documents can exist.
    setTtl(com.google.protobuf.Duration.Builder builderForValue)
    The duration for which all media assets, associated metadata, and search documents can exist.

    Methods inherited from class com.google.protobuf.GeneratedMessage.Builder

    addRepeatedField, clearField, clearOneof, clone, getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownFields, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setField, setRepeatedField, setUnknownFields, setUnknownFieldSetBuilder, setUnknownFieldsProto3

    Methods inherited from class com.google.protobuf.AbstractMessage.Builder

    findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toString

    Methods inherited from class com.google.protobuf.AbstractMessageLite.Builder

    addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageException

    Methods inherited from class java.lang.Object

    equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

    Methods inherited from interface com.google.protobuf.Message.Builder

    mergeDelimitedFrom, mergeDelimitedFrom

    Methods inherited from interface com.google.protobuf.MessageLite.Builder

    mergeFrom

    Methods inherited from interface com.google.protobuf.MessageOrBuilder

    findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
  • 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.Builder<Asset.Builder>
    • clear

      public Asset.Builder clear()
      Specified by:
      clear in interface com.google.protobuf.Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class com.google.protobuf.GeneratedMessage.Builder<Asset.Builder>
    • getDescriptorForType

      public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface com.google.protobuf.Message.Builder
      Specified by:
      getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class com.google.protobuf.GeneratedMessage.Builder<Asset.Builder>
    • getDefaultInstanceForType

      public Asset getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
    • build

      public Asset build()
      Specified by:
      build in interface com.google.protobuf.Message.Builder
      Specified by:
      build in interface com.google.protobuf.MessageLite.Builder
    • buildPartial

      public Asset buildPartial()
      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • mergeFrom

      public Asset.Builder mergeFrom(com.google.protobuf.Message other)
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<Asset.Builder>
    • mergeFrom

      public Asset.Builder mergeFrom(Asset other)
    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessage.Builder<Asset.Builder>
    • mergeFrom

      public Asset.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Specified by:
      mergeFrom in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<Asset.Builder>
      Throws:
      IOException
    • getName

      public String getName()
       Resource name of the asset.
       Format:
       `projects/{project_number}/locations/{location_id}/corpora/{corpus_id}/assets/{asset_id}`
       
      string name = 1;
      Specified by:
      getName in interface AssetOrBuilder
      Returns:
      The name.
    • getNameBytes

      public com.google.protobuf.ByteString getNameBytes()
       Resource name of the asset.
       Format:
       `projects/{project_number}/locations/{location_id}/corpora/{corpus_id}/assets/{asset_id}`
       
      string name = 1;
      Specified by:
      getNameBytes in interface AssetOrBuilder
      Returns:
      The bytes for name.
    • setName

      public Asset.Builder setName(String value)
       Resource name of the asset.
       Format:
       `projects/{project_number}/locations/{location_id}/corpora/{corpus_id}/assets/{asset_id}`
       
      string name = 1;
      Parameters:
      value - The name to set.
      Returns:
      This builder for chaining.
    • clearName

      public Asset.Builder clearName()
       Resource name of the asset.
       Format:
       `projects/{project_number}/locations/{location_id}/corpora/{corpus_id}/assets/{asset_id}`
       
      string name = 1;
      Returns:
      This builder for chaining.
    • setNameBytes

      public Asset.Builder setNameBytes(com.google.protobuf.ByteString value)
       Resource name of the asset.
       Format:
       `projects/{project_number}/locations/{location_id}/corpora/{corpus_id}/assets/{asset_id}`
       
      string name = 1;
      Parameters:
      value - The bytes for name to set.
      Returns:
      This builder for chaining.
    • hasTtl

      public boolean hasTtl()
       The duration for which all media assets, associated metadata, and search
       documents can exist. If not set, then it will using the default ttl in the
       parent corpus resource.
       
      .google.protobuf.Duration ttl = 2;
      Specified by:
      hasTtl in interface AssetOrBuilder
      Returns:
      Whether the ttl field is set.
    • getTtl

      public com.google.protobuf.Duration getTtl()
       The duration for which all media assets, associated metadata, and search
       documents can exist. If not set, then it will using the default ttl in the
       parent corpus resource.
       
      .google.protobuf.Duration ttl = 2;
      Specified by:
      getTtl in interface AssetOrBuilder
      Returns:
      The ttl.
    • setTtl

      public Asset.Builder setTtl(com.google.protobuf.Duration value)
       The duration for which all media assets, associated metadata, and search
       documents can exist. If not set, then it will using the default ttl in the
       parent corpus resource.
       
      .google.protobuf.Duration ttl = 2;
    • setTtl

      public Asset.Builder setTtl(com.google.protobuf.Duration.Builder builderForValue)
       The duration for which all media assets, associated metadata, and search
       documents can exist. If not set, then it will using the default ttl in the
       parent corpus resource.
       
      .google.protobuf.Duration ttl = 2;
    • mergeTtl

      public Asset.Builder mergeTtl(com.google.protobuf.Duration value)
       The duration for which all media assets, associated metadata, and search
       documents can exist. If not set, then it will using the default ttl in the
       parent corpus resource.
       
      .google.protobuf.Duration ttl = 2;
    • clearTtl

      public Asset.Builder clearTtl()
       The duration for which all media assets, associated metadata, and search
       documents can exist. If not set, then it will using the default ttl in the
       parent corpus resource.
       
      .google.protobuf.Duration ttl = 2;
    • getTtlBuilder

      public com.google.protobuf.Duration.Builder getTtlBuilder()
       The duration for which all media assets, associated metadata, and search
       documents can exist. If not set, then it will using the default ttl in the
       parent corpus resource.
       
      .google.protobuf.Duration ttl = 2;
    • getTtlOrBuilder

      public com.google.protobuf.DurationOrBuilder getTtlOrBuilder()
       The duration for which all media assets, associated metadata, and search
       documents can exist. If not set, then it will using the default ttl in the
       parent corpus resource.
       
      .google.protobuf.Duration ttl = 2;
      Specified by:
      getTtlOrBuilder in interface AssetOrBuilder
    • hasAssetGcsSource

      public boolean hasAssetGcsSource()
       Output only. The original cloud storage source uri that is associated with
       this asset.
       
      .google.cloud.visionai.v1.AssetSource.AssetGcsSource asset_gcs_source = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      hasAssetGcsSource in interface AssetOrBuilder
      Returns:
      Whether the assetGcsSource field is set.
    • getAssetGcsSource

      public AssetSource.AssetGcsSource getAssetGcsSource()
       Output only. The original cloud storage source uri that is associated with
       this asset.
       
      .google.cloud.visionai.v1.AssetSource.AssetGcsSource asset_gcs_source = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getAssetGcsSource in interface AssetOrBuilder
      Returns:
      The assetGcsSource.
    • setAssetGcsSource

      public Asset.Builder setAssetGcsSource(AssetSource.AssetGcsSource value)
       Output only. The original cloud storage source uri that is associated with
       this asset.
       
      .google.cloud.visionai.v1.AssetSource.AssetGcsSource asset_gcs_source = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • setAssetGcsSource

      public Asset.Builder setAssetGcsSource(AssetSource.AssetGcsSource.Builder builderForValue)
       Output only. The original cloud storage source uri that is associated with
       this asset.
       
      .google.cloud.visionai.v1.AssetSource.AssetGcsSource asset_gcs_source = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • mergeAssetGcsSource

      public Asset.Builder mergeAssetGcsSource(AssetSource.AssetGcsSource value)
       Output only. The original cloud storage source uri that is associated with
       this asset.
       
      .google.cloud.visionai.v1.AssetSource.AssetGcsSource asset_gcs_source = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • clearAssetGcsSource

      public Asset.Builder clearAssetGcsSource()
       Output only. The original cloud storage source uri that is associated with
       this asset.
       
      .google.cloud.visionai.v1.AssetSource.AssetGcsSource asset_gcs_source = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • getAssetGcsSourceBuilder

      public AssetSource.AssetGcsSource.Builder getAssetGcsSourceBuilder()
       Output only. The original cloud storage source uri that is associated with
       this asset.
       
      .google.cloud.visionai.v1.AssetSource.AssetGcsSource asset_gcs_source = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • getAssetGcsSourceOrBuilder

      public AssetSource.AssetGcsSourceOrBuilder getAssetGcsSourceOrBuilder()
       Output only. The original cloud storage source uri that is associated with
       this asset.
       
      .google.cloud.visionai.v1.AssetSource.AssetGcsSource asset_gcs_source = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getAssetGcsSourceOrBuilder in interface AssetOrBuilder