public class DocumentRevisionBuilder
extends java.lang.Object
Build DocumentRevision
s in a chained manner.
Constructor and Description |
---|
DocumentRevisionBuilder() |
Modifier and Type | Method and Description |
---|---|
DocumentRevision |
build()
Builds and returns the
DocumentRevision for this builder. |
ProjectedDocumentRevision |
buildProjected()
Builds and returns the
ProjectedDocumentRevision for this builder. |
DocumentRevisionBuilder |
setAttachments(java.util.List<? extends Attachment> attachments)
Sets the attachments associated with the document for this builder.
|
DocumentRevisionBuilder |
setBody(DocumentBody body)
Sets the document body for this builder.
|
DocumentRevisionBuilder |
setCurrent(boolean current)
Sets whether this builder is creating the winning revision.
|
DocumentRevisionBuilder |
setDatastore(Datastore datastore)
Sets the datastore for this builder.
|
DocumentRevisionBuilder |
setDeleted(boolean deleted)
Sets whether this builder is creating a deleted revsion.
|
DocumentRevisionBuilder |
setDocId(java.lang.String docId)
Sets the document ID for this builder.
|
DocumentRevisionBuilder |
setInternalId(long internalId)
Sets the internal ID for this builder.
|
DocumentRevisionBuilder |
setParent(long parent)
Sets the parent sequence number for this builder.
|
DocumentRevisionBuilder |
setRevId(java.lang.String revId)
Sets the revision ID for this builder.
|
DocumentRevisionBuilder |
setSequence(long sequence)
Sets the sequence number for this builder.
|
public DocumentRevision build()
Builds and returns the DocumentRevision
for this builder.
DocumentRevision
for this builderpublic DocumentRevisionBuilder setDocId(java.lang.String docId)
Sets the document ID for this builder.
docId
- document IDpublic DocumentRevisionBuilder setRevId(java.lang.String revId)
Sets the revision ID for this builder.
revId
- revision IDpublic DocumentRevisionBuilder setBody(DocumentBody body)
Sets the document body for this builder.
body
- document revision bodypublic DocumentRevisionBuilder setCurrent(boolean current)
Sets whether this builder is creating the winning revision.
current
- whether this document revision is the winning revisionpublic DocumentRevisionBuilder setDeleted(boolean deleted)
Sets whether this builder is creating a deleted revsion.
deleted
- whether this revision is deletedpublic DocumentRevisionBuilder setInternalId(long internalId)
Sets the internal ID for this builder.
internalId
- revision internal IDpublic DocumentRevisionBuilder setSequence(long sequence)
Sets the sequence number for this builder.
sequence
- sequence numberpublic DocumentRevisionBuilder setParent(long parent)
Sets the parent sequence number for this builder.
parent
- parent sequence numberpublic DocumentRevisionBuilder setAttachments(java.util.List<? extends Attachment> attachments)
Sets the attachments associated with the document for this builder.
attachments
- list of attachments associated with the documentpublic DocumentRevisionBuilder setDatastore(Datastore datastore)
Sets the datastore for this builder.
datastore
- the datastorepublic ProjectedDocumentRevision buildProjected()
ProjectedDocumentRevision
for this builder.ProjectedDocumentRevision
for this builder.