Class: Google::Apis::DocumentaiV1::GoogleCloudDocumentaiV1DocumentBlobAsset

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/documentai_v1/classes.rb,
lib/google/apis/documentai_v1/representations.rb,
lib/google/apis/documentai_v1/representations.rb

Overview

Represents a blob asset. It's used to store the content of the inline blob in this document, for example, image bytes, such that it can be referenced by other fields in the document via asset ID.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudDocumentaiV1DocumentBlobAsset

Returns a new instance of GoogleCloudDocumentaiV1DocumentBlobAsset.



3489
3490
3491
# File 'lib/google/apis/documentai_v1/classes.rb', line 3489

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#asset_idString

Optional. The id of the blob asset. Corresponds to the JSON property assetId

Returns:

  • (String)


3475
3476
3477
# File 'lib/google/apis/documentai_v1/classes.rb', line 3475

def asset_id
  @asset_id
end

#contentString

Optional. The content of the blob asset, for example, image bytes. Corresponds to the JSON property content NOTE: Values are automatically base64 encoded/decoded in the client library.

Returns:

  • (String)


3481
3482
3483
# File 'lib/google/apis/documentai_v1/classes.rb', line 3481

def content
  @content
end

#mime_typeString

The mime type of the blob asset. An IANA published media type (MIME type). Corresponds to the JSON property mimeType

Returns:

  • (String)


3487
3488
3489
# File 'lib/google/apis/documentai_v1/classes.rb', line 3487

def mime_type
  @mime_type
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



3494
3495
3496
3497
3498
# File 'lib/google/apis/documentai_v1/classes.rb', line 3494

def update!(**args)
  @asset_id = args[:asset_id] if args.key?(:asset_id)
  @content = args[:content] if args.key?(:content)
  @mime_type = args[:mime_type] if args.key?(:mime_type)
end