Reference documentation and code samples for the Google Cloud Discovery Engine V1 Client class Content.
Unstructured data linked to this document.
Generated from protobuf message google.cloud.discoveryengine.v1.Document.Content
Namespace
Google \ Cloud \ DiscoveryEngine \ V1 \ DocumentMethods
__construct
Constructor.
data
array
Optional. Data for populating the Message object.
↳ raw_bytes
string
The content represented as a stream of bytes. The maximum length is 1,000,000 bytes (1 MB / ~0.95 MiB). Note: As with all bytes
fields, this field is represented as pure binary in Protocol Buffers and base64-encoded string in JSON. For example, abc123!?$*&()'-=@~
should be represented as YWJjMTIzIT8kKiYoKSctPUB+
in JSON. See https://developers.google.com/protocol-buffers/docs/proto3#json
.
↳ uri
string
The URI of the content. Only Cloud Storage URIs (e.g. gs://bucket-name/path/to/file
) are supported. The maximum file size is 2.5 MB for text-based formats, 200 MB for other formats.
↳ mime_type
string
The MIME type of the content. Supported types: * * application/pdf
(PDF, only native PDFs are supported for now) * * text/html
(HTML) * * text/plain
(TXT) * * application/xml
or text/xml
(XML) * * application/json
(JSON) * * application/vnd.openxmlformats-officedocument.wordprocessingml.document
(DOCX) * * application/vnd.openxmlformats-officedocument.presentationml.presentation
(PPTX) * * application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
(XLSX) * * application/vnd.ms-excel.sheet.macroenabled.12
(XLSM) The following types are supported only if layout parser is enabled in the data store: * * image/bmp
(BMP) * * image/gif
(GIF) * * image/jpeg
(JPEG) * * image/png
(PNG) * * image/tiff
(TIFF) See https://www.iana.org/assignments/media-types/media-types.xhtml
.
getRawBytes
The content represented as a stream of bytes. The maximum length is 1,000,000 bytes (1 MB / ~0.95 MiB).
Note: As with all bytes
fields, this field is represented as pure
binary in Protocol Buffers and base64-encoded string in JSON. For
example, abc123!?$*&()'-=@~
should be represented as YWJjMTIzIT8kKiYoKSctPUB+
in JSON. See https://developers.google.com/protocol-buffers/docs/proto3#json
.
string
hasRawBytes
setRawBytes
The content represented as a stream of bytes. The maximum length is 1,000,000 bytes (1 MB / ~0.95 MiB).
Note: As with all bytes
fields, this field is represented as pure
binary in Protocol Buffers and base64-encoded string in JSON. For
example, abc123!?$*&()'-=@~
should be represented as YWJjMTIzIT8kKiYoKSctPUB+
in JSON. See https://developers.google.com/protocol-buffers/docs/proto3#json
.
var
string
$this
getUri
The URI of the content. Only Cloud Storage URIs (e.g.
gs://bucket-name/path/to/file
) are supported. The maximum file size
is 2.5 MB for text-based formats, 200 MB for other formats.
string
hasUri
setUri
The URI of the content. Only Cloud Storage URIs (e.g.
gs://bucket-name/path/to/file
) are supported. The maximum file size
is 2.5 MB for text-based formats, 200 MB for other formats.
var
string
$this
getMimeType
The MIME type of the content. Supported types:
-
application/pdf
(PDF, only native PDFs are supported for now) -
text/html
(HTML) -
text/plain
(TXT) -
application/xml
ortext/xml
(XML) -
application/json
(JSON) -
application/vnd.openxmlformats-officedocument.wordprocessingml.document
(DOCX) -
application/vnd.openxmlformats-officedocument.presentationml.presentation
(PPTX) -
application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
(XLSX) -
application/vnd.ms-excel.sheet.macroenabled.12
(XLSM) The following types are supported only if layout parser is enabled in the data store: -
image/bmp
(BMP) -
image/gif
(GIF) -
image/jpeg
(JPEG) -
image/png
(PNG) -
image/tiff
(TIFF) See https://www.iana.org/assignments/media-types/media-types.xhtml .
string
setMimeType
The MIME type of the content. Supported types:
-
application/pdf
(PDF, only native PDFs are supported for now) -
text/html
(HTML) -
text/plain
(TXT) -
application/xml
ortext/xml
(XML) -
application/json
(JSON) -
application/vnd.openxmlformats-officedocument.wordprocessingml.document
(DOCX) -
application/vnd.openxmlformats-officedocument.presentationml.presentation
(PPTX) -
application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
(XLSX) -
application/vnd.ms-excel.sheet.macroenabled.12
(XLSM) The following types are supported only if layout parser is enabled in the data store: -
image/bmp
(BMP) -
image/gif
(GIF) -
image/jpeg
(JPEG) -
image/png
(PNG) -
image/tiff
(TIFF) See https://www.iana.org/assignments/media-types/media-types.xhtml .
var
string
$this
getContent
string