Package com.itextpdf.forms.fields
Class ChoiceFormFieldBuilder
java.lang.Object
com.itextpdf.forms.fields.FormFieldBuilder
com.itextpdf.forms.fields.TerminalFormFieldBuilder<ChoiceFormFieldBuilder>
com.itextpdf.forms.fields.ChoiceFormFieldBuilder
Builder for choice form field.
-
Constructor Summary
ConstructorsConstructorDescriptionChoiceFormFieldBuilder(PdfDocument document, String formFieldName) Creates builder forPdfChoiceFormFieldcreation. -
Method Summary
Modifier and TypeMethodDescriptionCreates combobox form field base on provided parameters.Creates list form field based on provided parameters.Gets options for choice form field.protected ChoiceFormFieldBuildergetThis()Returns this builder object.setOptions(PdfArray options) Sets options for choice form field.setOptions(String[] options) Sets options for choice form field.setOptions(String[][] options) Sets options for choice form field.Methods inherited from class com.itextpdf.forms.fields.TerminalFormFieldBuilder
getFont, getPage, getWidgetRectangle, setFont, setPage, setPage, setWidgetRectangleMethods inherited from class com.itextpdf.forms.fields.FormFieldBuilder
getConformance, getDocument, getFormFieldName, setConformance
-
Constructor Details
-
ChoiceFormFieldBuilder
Creates builder forPdfChoiceFormFieldcreation.- Parameters:
-
document- document to be used for form field creation -
formFieldName- name of the form field
-
-
Method Details
-
getOptions
Gets options for choice form field.- Returns:
-
PdfArrayof choice form field options
-
setOptions
Sets options for choice form field.- Parameters:
-
options-PdfArrayof choice form field options - Returns:
- this builder
-
setOptions
Sets options for choice form field.- Parameters:
-
options- array ofStringoptions - Returns:
- this builder
-
setOptions
Sets options for choice form field.- Parameters:
-
options- two-dimensional array ofStringoptions. Every inner array shall have two elements. - Returns:
- this builder
-
createList
Creates list form field based on provided parameters.- Returns:
-
new
PdfChoiceFormFieldinstance
-
createComboBox
Creates combobox form field base on provided parameters.- Returns:
-
new
PdfChoiceFormFieldinstance
-
getThis
Returns this builder object. Required for superclass methods.- Specified by:
-
getThisin classFormFieldBuilder<ChoiceFormFieldBuilder> - Returns:
- this builder
-