[![](https://developers.google.com/dotnet/docs/reference/Google.Developers.DeveloperKnowledge.V1/latest/logo.svg)](https://developers.google.com/dotnet/docs/reference/Google.Developers.DeveloperKnowledge.V1/latest/index.html)
- 
[Show / Hide Table of Contents](https://developers.google.com/dotnet/docs/reference/Google.Developers.DeveloperKnowledge.V1/latest/api/Google.Developers.DeveloperKnowledge.V1.DocumentChunk#sidetoggle) A DocumentChunk represents a piece of content from a
\[Document\]\[google.developers.knowledge.v1.Document\] in the DeveloperKnowledge
corpus. To fetch the entire document content, pass the `parent` to
\[DeveloperKnowledge.GetDocument\]\[google.developers.knowledge.v1.DeveloperKnowledge.GetDocument\]
or
\[DeveloperKnowledge.BatchGetDocuments\]\[google.developers.knowledge.v1.DeveloperKnowledge.BatchGetDocuments\].

##### Inheritance

[object](https://learn.microsoft.com/dotnet/api/system.object) DocumentChunk

##### Implements

[IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage-1.html)\<[DocumentChunk](https://developers.google.com/dotnet/docs/reference/Google.Developers.DeveloperKnowledge.V1/latest/api/Google.Developers.DeveloperKnowledge.V1.DocumentChunk)\> [IEquatable](https://learn.microsoft.com/dotnet/api/system.iequatable-1)\<[DocumentChunk](https://developers.google.com/dotnet/docs/reference/Google.Developers.DeveloperKnowledge.V1/latest/api/Google.Developers.DeveloperKnowledge.V1.DocumentChunk)\> [IDeepCloneable](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IDeepCloneable-1.html)\<[DocumentChunk](https://developers.google.com/dotnet/docs/reference/Google.Developers.DeveloperKnowledge.V1/latest/api/Google.Developers.DeveloperKnowledge.V1.DocumentChunk)\> [IBufferMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IBufferMessage.html) [IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage.html)

##### Inherited Members

[object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode) [object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype) [object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)

###### **Namespace** : [Google](https://developers.google.com/dotnet/docs/reference/Google.Developers.DeveloperKnowledge.V1/latest/api/Google).[Developers](https://developers.google.com/dotnet/docs/reference/Google.Developers.DeveloperKnowledge.V1/latest/api/Google.Developers).[DeveloperKnowledge](https://developers.google.com/dotnet/docs/reference/Google.Developers.DeveloperKnowledge.V1/latest/api/Google.Developers.DeveloperKnowledge).[V1](https://developers.google.com/dotnet/docs/reference/Google.Developers.DeveloperKnowledge.V1/latest/api/Google.Developers.DeveloperKnowledge.V1)

###### **Assembly**: Google.Developers.DeveloperKnowledge.V1.dll

##### Syntax

    public sealed class DocumentChunk : IMessage<DocumentChunk>, IEquatable<DocumentChunk>, IDeepCloneable<DocumentChunk>, IBufferMessage, IMessage

### Constructors

#### DocumentChunk()

##### Declaration

    public DocumentChunk()

#### DocumentChunk(DocumentChunk)

##### Declaration

    public DocumentChunk(DocumentChunk other)

##### Parameters

| Type | Name | Description |
|---|---|---|
| [DocumentChunk](https://developers.google.com/dotnet/docs/reference/Google.Developers.DeveloperKnowledge.V1/latest/api/Google.Developers.DeveloperKnowledge.V1.DocumentChunk) | other |   |

### Properties

#### Content

Output only. Contains the content of the document chunk.

##### Declaration

    public string Content { get; set; }

##### Property Value

| Type | Description |
|---|---|
| [string](https://learn.microsoft.com/dotnet/api/system.string) |   |

#### Document

Output only. Represents metadata about the
\[Document\]\[google.developers.knowledge.v1.Document\] this chunk is from. The
\[DocumentView\]\[google.developers.knowledge.v1.DocumentView\] of this
\[Document\]\[google.developers.knowledge.v1.Document\] message will be set to
`DOCUMENT_VIEW_BASIC`. It is included here for convenience so that clients
do not need to call
\[DeveloperKnowledge.GetDocument\]\[google.developers.knowledge.v1.DeveloperKnowledge.GetDocument\]
or
\[DeveloperKnowledge.BatchGetDocuments\]\[google.developers.knowledge.v1.DeveloperKnowledge.BatchGetDocuments\]
if they only need the metadata fields. Otherwise, clients should use
\[DeveloperKnowledge.GetDocument\]\[google.developers.knowledge.v1.DeveloperKnowledge.GetDocument\]
or
\[DeveloperKnowledge.BatchGetDocuments\]\[google.developers.knowledge.v1.DeveloperKnowledge.BatchGetDocuments\]
to fetch the full document content.

##### Declaration

    public Document Document { get; set; }

##### Property Value

| Type | Description |
|---|---|
| [Document](https://developers.google.com/dotnet/docs/reference/Google.Developers.DeveloperKnowledge.V1/latest/api/Google.Developers.DeveloperKnowledge.V1.Document) |   |

#### Id

Output only. Specifies the ID of this chunk within the document. The chunk
ID is unique within a document, but not globally unique across documents.
The chunk ID is not stable and may change over time.

##### Declaration

    public string Id { get; set; }

##### Property Value

| Type | Description |
|---|---|
| [string](https://learn.microsoft.com/dotnet/api/system.string) |   |

#### Parent

Output only. Contains the resource name of the document this chunk is from.
Format: `documents/{uri_without_scheme}`
Example: `documents/docs.cloud.google.com/storage/docs/creating-buckets`

##### Declaration

    public string Parent { get; set; }

##### Property Value

| Type | Description |
|---|---|
| [string](https://learn.microsoft.com/dotnet/api/system.string) |   |

#### ParentAsDocumentName

[DocumentName](https://developers.google.com/dotnet/docs/reference/Google.Developers.DeveloperKnowledge.V1/latest/api/Google.Developers.DeveloperKnowledge.V1.DocumentName)-typed view over the [Parent](https://developers.google.com/dotnet/docs/reference/Google.Developers.DeveloperKnowledge.V1/latest/api/Google.Developers.DeveloperKnowledge.V1.DocumentChunk#Google_Developers_DeveloperKnowledge_V1_DocumentChunk_Parent) resource name property.

##### Declaration

    public DocumentName ParentAsDocumentName { get; set; }

##### Property Value

| Type | Description |
|---|---|
| [DocumentName](https://developers.google.com/dotnet/docs/reference/Google.Developers.DeveloperKnowledge.V1/latest/api/Google.Developers.DeveloperKnowledge.V1.DocumentName) |   |

##### In this article

[Back to top](https://developers.google.com/dotnet/docs/reference/Google.Developers.DeveloperKnowledge.V1/latest/api/Google.Developers.DeveloperKnowledge.V1.DocumentChunk#top) Generated by **DocFX**