Package com.ibm.cloud.cloudant.v1.model
Class Document.Builder
- java.lang.Object
-
- com.ibm.cloud.cloudant.v1.model.Document.Builder
-
-
Constructor Summary
Constructors Constructor Description Builder()
Instantiates a new builder.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Document.Builder
add(String name, Object value)
Add an arbitrary property.Document.Builder
addConflicts(String conflicts)
Adds an conflicts to conflicts.Document.Builder
addDeletedConflicts(String deletedConflicts)
Adds an deletedConflicts to deletedConflicts.Document.Builder
addRevsInfo(DocumentRevisionStatus revsInfo)
Adds an revsInfo to revsInfo.Document.Builder
attachments(Map<String,Attachment> attachments)
Set the attachments.Document
build()
Builds a Document.Document.Builder
conflicts(List<String> conflicts)
Set the conflicts.Document.Builder
deleted(Boolean deleted)
Set the deleted.Document.Builder
deletedConflicts(List<String> deletedConflicts)
Set the deletedConflicts.Document.Builder
id(String id)
Set the id.Document.Builder
localSeq(String localSeq)
Set the localSeq.Document.Builder
rev(String rev)
Set the rev.Document.Builder
revisions(Revisions revisions)
Set the revisions.Document.Builder
revsInfo(List<DocumentRevisionStatus> revsInfo)
Set the revsInfo.
-
-
-
Method Detail
-
build
public Document build()
Builds a Document.- Returns:
- the new Document instance
-
addConflicts
public Document.Builder addConflicts(String conflicts)
Adds an conflicts to conflicts.- Parameters:
conflicts
- the new conflicts- Returns:
- the Document builder
-
addDeletedConflicts
public Document.Builder addDeletedConflicts(String deletedConflicts)
Adds an deletedConflicts to deletedConflicts.- Parameters:
deletedConflicts
- the new deletedConflicts- Returns:
- the Document builder
-
addRevsInfo
public Document.Builder addRevsInfo(DocumentRevisionStatus revsInfo)
Adds an revsInfo to revsInfo.- Parameters:
revsInfo
- the new revsInfo- Returns:
- the Document builder
-
attachments
public Document.Builder attachments(Map<String,Attachment> attachments)
Set the attachments.- Parameters:
attachments
- the attachments- Returns:
- the Document builder
-
conflicts
public Document.Builder conflicts(List<String> conflicts)
Set the conflicts. Existing conflicts will be replaced.- Parameters:
conflicts
- the conflicts- Returns:
- the Document builder
-
deleted
public Document.Builder deleted(Boolean deleted)
Set the deleted.- Parameters:
deleted
- the deleted- Returns:
- the Document builder
-
deletedConflicts
public Document.Builder deletedConflicts(List<String> deletedConflicts)
Set the deletedConflicts. Existing deletedConflicts will be replaced.- Parameters:
deletedConflicts
- the deletedConflicts- Returns:
- the Document builder
-
id
public Document.Builder id(String id)
Set the id.- Parameters:
id
- the id- Returns:
- the Document builder
-
localSeq
public Document.Builder localSeq(String localSeq)
Set the localSeq.- Parameters:
localSeq
- the localSeq- Returns:
- the Document builder
-
rev
public Document.Builder rev(String rev)
Set the rev.- Parameters:
rev
- the rev- Returns:
- the Document builder
-
revisions
public Document.Builder revisions(Revisions revisions)
Set the revisions.- Parameters:
revisions
- the revisions- Returns:
- the Document builder
-
revsInfo
public Document.Builder revsInfo(List<DocumentRevisionStatus> revsInfo)
Set the revsInfo. Existing revsInfo will be replaced.- Parameters:
revsInfo
- the revsInfo- Returns:
- the Document builder
-
add
public Document.Builder add(String name, Object value)
Add an arbitrary property.- Parameters:
name
- the name of the property to addvalue
- the value of the property to add- Returns:
- the Document builder
-
-