SetaPDF_FormFiller_Field_ButtonGroup A radio button group
File: /SetaPDF v2/FormFiller/Field/ButtonGroup.php
Class hierarchy
Implements
Summary
Methods
- __construct()
- addButton()
- cleanUp()
- delete()
- flatten()
- getButtons()
- getDefaultButton()
- getDefaultValue()
- getFields()
- getName()
- getNoExport()
- getOriginalQualifiedName()
- getPageNumber()
- getQualifiedName()
- getTooltip()
- getValue()
- isReadOnly()
- isRequired()
- isSetValueActive()
- onFieldDeleted()
- setDefaultValue()
- setNoExport()
- setReadOnly()
- setRequired()
- setTooltip()
- setValue()
Properties
$_buttons
The buttons
$_qualifiedName
The qualified name of the button group
Methods
__construct()
The constructor.
Parameters
- $fields : SetaPDF_FormFiller_Fields
- $qualifiedName : string
- $fieldObject : SetaPDF_Core_Type_IndirectObject
Exceptions
Throws SetaPDF_Core_Type_Exception
addButton()
Add a button to the group.
Parameters
- $button : SetaPDF_FormFiller_Field_Button
delete()
Delete the button group.
Exceptions
Throws SetaPDF_Core_Exception
Throws SetaPDF_Core_SecHandler_Exception
Throws SetaPDF_Core_Type_Exception
flatten()
Flatten the button group to the pages content stream.
Parameters
- $recreateAppearanceIfNeedAppearancesIsSet : boolean
Defines whether the field appearance is re-created if the NeedAppearances flag is set.
Exceptions
Throws SetaPDF_Core_Document_ObjectNotFoundException
Throws SetaPDF_Core_Exception
Throws SetaPDF_Core_Parser_Pdf_InvalidTokenException
Throws SetaPDF_Core_Reader_Exception
Throws SetaPDF_Core_Type_Exception
Throws SetaPDF_Core_Type_IndirectReference_Exception
Throws SetaPDF_Exception
getDefaultButton()
Get the default checked button.
Exceptions
Throws SetaPDF_Core_Type_Exception
getDefaultValue()
Returns the default value of the button group.
This value is used if the form is reset
Parameters
- $encoding : string
See
getNoExport()
Get the info, if the button group is marked as "no export".
This flag is not get- or settable with Acrobat!
getOriginalQualifiedName()
Returns the original qualified name.
(which is the same as the qualified name for button groups)
getPageNumber()
Get the page number(s) on which the button group appears.
Exceptions
Throws SetaPDF_Core_Document_ObjectNotDefinedException
Throws SetaPDF_Core_Document_ObjectNotFoundException
Throws SetaPDF_Core_Exception
Throws SetaPDF_Core_Type_Exception
getTooltip()
Get the tooltip value.
Parameters
- $encoding : string
getValue()
Get the export value of the current active button.
This method returns the export value of the first checked button.
Exceptions
Throws SetaPDF_Core_Type_Exception
onFieldDeleted()
Is called when a button in this group is deleted.
Parameters
- $button : SetaPDF_FormFiller_Field_Button
setDefaultValue()
Set the default value of this button group.
Parameters
- $value : string|null|SetaPDF_FormFiller_Field_Button
- $encoding : string
Exceptions
Throws DOMException
Throws SetaPDF_Core_SecHandler_Exception
Throws SetaPDF_Core_Type_Exception
Throws SetaPDF_Exception
Throws SetaPDF_Exception_NotImplemented
Throws SetaPDF_FormFiller_Exception
setNoExport()
Sets the "no export" flag.
This flag is not get- or settable with Acrobat!
If you remove this flag, the element could be still not exported due to a definition in a FormSubmit actions Fields array.
Parameters
- $noExport : boolean
setTooltip()
Set the tooltip value.
Parameters
- $value : string|false
- $encoding : string
setValue()
Set the value / active button of the button group.
This method requires the button object, which should be activated as the parameter or an export value which will be used to find the desired button.
Parameters
- $value : SetaPDF_FormFiller_Field_Button|string
The button instance or an export value
Exceptions
Throws DOMException
Throws SetaPDF_Core_Exception
Throws SetaPDF_Core_Font_Exception
Throws SetaPDF_Core_Parser_Pdf_InvalidTokenException
Throws SetaPDF_Core_SecHandler_Exception
Throws SetaPDF_Core_Type_Exception
Throws SetaPDF_Core_Type_IndirectReference_Exception
Throws SetaPDF_Exception
Throws SetaPDF_Exception_NotImplemented
Throws SetaPDF_FormFiller_Exception