public abstract class AbstractRequest extends AbstractResource
Modifier and Type | Field and Description |
---|---|
static String |
REQUEST_CLIENT_ID |
static String |
REQUEST_HIDE_TEXT_TAGS |
static String |
REQUEST_MESSAGE |
static String |
REQUEST_METADATA |
static String |
REQUEST_REDIRECT_URL |
static String |
REQUEST_SUBJECT |
static String |
REQUEST_TEST_MODE |
static String |
REQUEST_TITLE |
static String |
REQUEST_USE_PREEXISTING_FIELDS |
static String |
REQUEST_USE_TEXT_TAGS |
static String |
REQUEST_UX_VERSION |
static int |
UX_VERSION_1 |
static int |
UX_VERSION_2 |
dataObj, warnings
Constructor and Description |
---|
AbstractRequest() |
AbstractRequest(org.json.JSONObject json,
String optionalKey) |
Modifier and Type | Method and Description |
---|---|
void |
addDocument(Document doc)
Adds a Document to the signature request.
|
void |
addDocument(Document doc,
int order)
Adds a Document to the signature request at the specific order.
|
void |
addFile(File file)
Adds the file to the request.
|
void |
addFile(File file,
Integer order)
Adds the file to the request in the given order.
|
void |
addFileUrl(String url)
Add a file_url to this request.
|
void |
addMetadata(String key,
String value) |
void |
clearDocuments()
Remove all documents from this request.
|
String |
getClientId()
The API app client ID that has been associated with
this signature request.
|
List<Document> |
getDocuments()
Returns a reference to the list of documents for this request.
|
List<String> |
getFileUrls()
Return the current file_url list.
|
abstract String |
getId() |
String |
getMessage() |
Metadata |
getMetadata() |
String |
getMetadata(String key) |
boolean |
getOrderMatters()
A flag that determines whether order of the signers list is enforced.
|
protected Map<String,Serializable> |
getPostFields() |
String |
getRedirectUrl() |
String |
getSubject() |
String |
getTitle() |
int |
getUxVersion()
Return the UX version for this request.
|
boolean |
hasHideTextTags() |
boolean |
hasMessage() |
boolean |
hasRedirectUrl() |
boolean |
hasSubject() |
boolean |
hasTitle() |
boolean |
hasUsePreexistingFields() |
boolean |
hasUseTextTags() |
Boolean |
isHidingTextTags() |
boolean |
isTestMode() |
Boolean |
isUsingPreexistingFields() |
Boolean |
isUsingTextTags() |
void |
setClientId(String clientId)
Associates this request with an API app.
|
void |
setDocuments(List<Document> docs)
Overwrites this requests document list with the provided document list.
|
void |
setFileUrls(List<String> fileUrls)
Overwrite the current file_url list.
|
void |
setHideTextTags(boolean hideTextTags) |
void |
setMessage(String message) |
void |
setOrderMatters(boolean b)
Determines whether the order of the signers list is to be enforced.
|
void |
setRedirectUrl(String url) |
void |
setSubject(String subject) |
void |
setTestMode(boolean testMode) |
void |
setTitle(String title) |
void |
setUsePreexistingFields(boolean usePreexistingFields) |
void |
setUseTextTags(boolean useTextTags) |
void |
setUxVersion(int uxVersion)
Set the UX version for this request.
|
add, addToList, clearList, get, getBoolean, getConstructor, getDate, getInteger, getJSONObject, getList, getList, getLong, getString, getWarnings, has, hasString, set, toString
public static final String REQUEST_TITLE
public static final String REQUEST_SUBJECT
public static final String REQUEST_MESSAGE
public static final String REQUEST_REDIRECT_URL
public static final String REQUEST_TEST_MODE
public static final String REQUEST_USE_TEXT_TAGS
public static final String REQUEST_USE_PREEXISTING_FIELDS
public static final String REQUEST_HIDE_TEXT_TAGS
public static final String REQUEST_METADATA
public static final String REQUEST_UX_VERSION
public static final String REQUEST_CLIENT_ID
public static final int UX_VERSION_1
public static final int UX_VERSION_2
public AbstractRequest()
public AbstractRequest(org.json.JSONObject json, String optionalKey) throws HelloSignException
HelloSignException
protected Map<String,Serializable> getPostFields() throws HelloSignException
HelloSignException
public abstract String getId()
public String getTitle()
public void setTitle(String title)
public boolean hasTitle()
public String getSubject()
public void setSubject(String subject)
public boolean hasSubject()
public String getMessage()
public void setMessage(String message)
public boolean hasMessage()
public void setTestMode(boolean testMode)
public boolean isTestMode()
public String getRedirectUrl()
public void setRedirectUrl(String url)
public boolean hasRedirectUrl()
public boolean hasUseTextTags()
public Boolean isUsingTextTags()
public void setUseTextTags(boolean useTextTags)
public boolean hasHideTextTags()
public Boolean isHidingTextTags()
public void setHideTextTags(boolean hideTextTags)
public boolean hasUsePreexistingFields()
public Boolean isUsingPreexistingFields()
public void setUsePreexistingFields(boolean usePreexistingFields)
public Metadata getMetadata()
public void addFile(File file) throws HelloSignException
file
- FileHelloSignException
- thrown if there is a problem attaching
the File to this request.public void addFile(File file, Integer order) throws HelloSignException
file
- Fileorder
- Integer or nullHelloSignException
- thrown if there is a problem attaching
the File to this request.public void addDocument(Document doc) throws HelloSignException
doc
- DocumentHelloSignException
- thrown if null is providedpublic void addDocument(Document doc, int order) throws HelloSignException
doc
- Documentorder
- intHelloSignException
- thrown if null is provided or there
is a problem attaching the Document.public List<Document> getDocuments()
public void setDocuments(List<Document> docs)
docs
- Listpublic void clearDocuments()
public void setOrderMatters(boolean b)
b
- true if the order matters, false otherwisepublic boolean getOrderMatters()
public void addFileUrl(String url)
url
- Stringpublic void setFileUrls(List<String> fileUrls)
fileUrls
- Listpublic void setUxVersion(int uxVersion)
uxVersion
- intpublic int getUxVersion()
public void setClientId(String clientId) throws HelloSignException
clientId
- String client ID of the API app.HelloSignException
public String getClientId()
Copyright © 2016 HelloSign. All rights reserved.