Reference documentation and code samples for the Google Cloud Document Ai V1 Client class Chunk.
Represents a chunk.
Generated from protobuf message google.cloud.documentai.v1.Document.ChunkedDocument.Chunk
Namespace
Google \ Cloud \ DocumentAI \ V1 \ Document \ ChunkedDocumentMethods
__construct
Constructor.
Parameters | |
---|---|
Name | Description |
data |
array
Optional. Data for populating the Message object. |
↳ chunk_id |
string
ID of the chunk. |
↳ source_block_ids |
array
Unused. |
↳ content |
string
Text content of the chunk. |
↳ page_span |
Google\Cloud\DocumentAI\V1\Document\ChunkedDocument\Chunk\ChunkPageSpan
Page span of the chunk. |
↳ page_headers |
array<Google\Cloud\DocumentAI\V1\Document\ChunkedDocument\Chunk\ChunkPageHeader>
Page headers associated with the chunk. |
↳ page_footers |
array<Google\Cloud\DocumentAI\V1\Document\ChunkedDocument\Chunk\ChunkPageFooter>
Page footers associated with the chunk. |
getChunkId
ID of the chunk.
Returns | |
---|---|
Type | Description |
string |
setChunkId
ID of the chunk.
Parameter | |
---|---|
Name | Description |
var |
string
|
Returns | |
---|---|
Type | Description |
$this |
getSourceBlockIds
Unused.
Returns | |
---|---|
Type | Description |
Google\Protobuf\Internal\RepeatedField |
setSourceBlockIds
Unused.
Parameter | |
---|---|
Name | Description |
var |
string[]
|
Returns | |
---|---|
Type | Description |
$this |
getContent
Text content of the chunk.
Returns | |
---|---|
Type | Description |
string |
setContent
Text content of the chunk.
Parameter | |
---|---|
Name | Description |
var |
string
|
Returns | |
---|---|
Type | Description |
$this |
getPageSpan
Page span of the chunk.
Returns | |
---|---|
Type | Description |
Google\Cloud\DocumentAI\V1\Document\ChunkedDocument\Chunk\ChunkPageSpan|null |
hasPageSpan
clearPageSpan
setPageSpan
Page span of the chunk.
Parameter | |
---|---|
Name | Description |
var |
Google\Cloud\DocumentAI\V1\Document\ChunkedDocument\Chunk\ChunkPageSpan
|
Returns | |
---|---|
Type | Description |
$this |
getPageHeaders
Page headers associated with the chunk.
Returns | |
---|---|
Type | Description |
Google\Protobuf\Internal\RepeatedField |
setPageHeaders
Page headers associated with the chunk.
Parameter | |
---|---|
Name | Description |
var |
array<Google\Cloud\DocumentAI\V1\Document\ChunkedDocument\Chunk\ChunkPageHeader>
|
Returns | |
---|---|
Type | Description |
$this |
getPageFooters
Page footers associated with the chunk.
Returns | |
---|---|
Type | Description |
Google\Protobuf\Internal\RepeatedField |
setPageFooters
Page footers associated with the chunk.
Parameter | |
---|---|
Name | Description |
var |
array<Google\Cloud\DocumentAI\V1\Document\ChunkedDocument\Chunk\ChunkPageFooter>
|
Returns | |
---|---|
Type | Description |
$this |