public class FormField extends CustomField
CUSTOM_FIELD_API_ID, CUSTOM_FIELD_AVG_TEXT_LENGTH, CUSTOM_FIELD_EDITOR, CUSTOM_FIELD_HEIGHT, CUSTOM_FIELD_NAME, CUSTOM_FIELD_NUM_CHARS_PER_LINE, CUSTOM_FIELD_NUM_LINES, CUSTOM_FIELD_REQUIRED, CUSTOM_FIELD_TYPE, CUSTOM_FIELD_VALUE, CUSTOM_FIELD_WIDTH, CUSTOM_FIELD_X, CUSTOM_FIELD_Y
dataObj, warnings
Constructor and Description |
---|
FormField() |
FormField(FieldType type,
String name,
int signer,
int x,
int y,
int height,
int width,
int page)
Constructor to be used when creating a new FormField object.
|
FormField(org.json.JSONObject json) |
Modifier and Type | Method and Description |
---|---|
Integer |
getPage()
Returns the page number this component is on.
|
Integer |
getSigner()
Returns the signer index for this form field.
|
ValidationType |
getValidationType()
Return the validation rule being used for this field
|
String |
getValidationTypeString()
Return the validation rule being used for this field as a string
|
void |
setPage(Integer page)
Set the page number for this component.
|
void |
setRequired(boolean isRequired)
Deprecated.
|
void |
setSigner(Integer signer)
Set the signer index that should complete this form field.
|
void |
setValidationType(ValidationType type)
Set the validation rule for this field.
|
getApiId, getEditor, getEstimatedCharsPerLine, getEstimatedTextLines, getHeight, getName, getType, getTypeString, getValue, getWidth, getX, getY, isRequired, setApiId, setEditor, setHeight, setIsRequired, setName, setType, setValue, setWidth, setX, setY
add, addToList, clearList, get, getBoolean, getConstructor, getDate, getInteger, getJSONObject, getList, getList, getLong, getString, getWarnings, has, hasString, set, toString, toString
public FormField()
public FormField(org.json.JSONObject json) throws HelloSignException
HelloSignException
public FormField(FieldType type, String name, int signer, int x, int y, int height, int width, int page)
type
- FormField typename
- String Field Label that will be displayed to the signersigner
- int index of the signer that should complete this field (0-based index)x
- int x coordinate location of this field in pixelsy
- int y coordinate location of this field in pixelsheight
- int height of this field in pixelswidth
- int width of this field in pixelspage
- int page number of the document in which this field will be placed (1-based index)public Integer getSigner()
public void setSigner(Integer signer)
signer
- Integer indexpublic void setPage(Integer page)
page
- Integer page numberpublic Integer getPage()
public void setValidationType(ValidationType type)
type
- ValidationTypepublic ValidationType getValidationType()
public String getValidationTypeString()
public void setRequired(boolean isRequired)
CustomField.setIsRequired(Boolean)
isRequired
- boolean true if field is required by signerCopyright © 2017 HelloSign. All rights reserved.