|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.silanis.esl.sdk.builder.DocumentBuilder
public class DocumentBuilder
DocumentBuilder class is used to facilitate the creation and customization of a document.
Field Summary | |
---|---|
static String |
DEFAULT_NAME
|
Constructor Summary | |
---|---|
DocumentBuilder()
|
|
DocumentBuilder(String name)
The constructor of this class. |
Method Summary | |
---|---|
DocumentBuilder |
atIndex(int index)
Defines the order that documents must be signed in. |
Document |
build()
Builds the actual document |
DocumentBuilder |
enableExtraction()
Enables the extraction operation against the document. |
DocumentBuilder |
fromFile(String fileName)
Creates a signing ceremony document from a file on the file system. |
DocumentBuilder |
fromStream(InputStream input,
DocumentType type)
Creates a signing ceremony document from a stream. |
static DocumentBuilder |
newDocumentWithName(String name)
Creates the document. |
DocumentBuilder |
withData(DocumentAttributesBuilder builder)
Set this document's data |
DocumentBuilder |
withData(Map<String,Object> data)
Set this document's data |
DocumentBuilder |
withDescription(String description)
Set this document's description |
DocumentBuilder |
withExternal(External external)
|
DocumentBuilder |
withExtractionType(ExtractionType extractionType)
Set this document's extraction type |
DocumentBuilder |
withId(String id)
Sets the ID value of the document |
DocumentBuilder |
withInjectedField(Field field)
|
DocumentBuilder |
withInjectedField(FieldBuilder builder)
Set form fields (text, checkbox, etc...) that are stamped on the document. |
DocumentBuilder |
withQRCode(Field field)
Add QR code to the document. |
DocumentBuilder |
withQRCode(FieldBuilder builder)
Add QR code to the document. |
DocumentBuilder |
withSignature(Signature signature)
Adds a signature to the document. |
DocumentBuilder |
withSignature(SignatureBuilder builder)
Adds a signature to the document. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String DEFAULT_NAME
Constructor Detail |
---|
public DocumentBuilder()
public DocumentBuilder(String name)
The constructor of this class.
name
- the name of the document produced by the document builder. @size(max="64")Method Detail |
---|
public static DocumentBuilder newDocumentWithName(String name)
Creates the document.
name
- the name of the document. @size(max="64")
public DocumentBuilder enableExtraction()
public DocumentBuilder fromFile(String fileName)
fileName
- a valid file path
public DocumentBuilder fromStream(InputStream input, DocumentType type)
Creates a signing ceremony document from a stream.
input
- the document content input streamtype
- the document type
public DocumentBuilder withSignature(SignatureBuilder builder)
Adds a signature to the document.
The builder parameter is a convenient method to create and customize a signature.
builder
- the signature builder
public DocumentBuilder withSignature(Signature signature)
Adds a signature to the document.
signature
- the signature
public DocumentBuilder withExternal(External external)
public Document build()
Builds the actual document
public DocumentBuilder atIndex(int index)
Defines the order that documents must be signed in.
Thus, the documents with smaller values of their index will be shown first to the signer in the overall document workflow.
index
- the order of the document in the document workflow. @min="1"
public DocumentBuilder withId(String id)
id
- @size(min="1" max="255")
public DocumentBuilder withInjectedField(FieldBuilder builder)
builder
-
public DocumentBuilder withInjectedField(Field field)
public DocumentBuilder withQRCode(FieldBuilder builder)
builder
-
public DocumentBuilder withQRCode(Field field)
field
- the QR code field
public DocumentBuilder withDescription(String description)
description
- @size(max="255")
public DocumentBuilder withData(Map<String,Object> data)
data
-
public DocumentBuilder withData(DocumentAttributesBuilder builder)
builder
-
public DocumentBuilder withExtractionType(ExtractionType extractionType)
extractionType
-
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |