SetaPDF_FormFiller_Field_ButtonGroup A radio button group

File: /SetaPDF v2/FormFiller/Field/ButtonGroup.php

Class hierarchy

Implements

Summary

Properties

$_fieldDictionary

$_fields

A reference to the fields instance

$_qualifiedName

The qualified name of the button group

$_setValueActive

A flag indicating that a setValue call is active


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
 

cleanUp()

Release cycled references and release memory.

See

flatten()

public SetaPDF_FormFiller_Field_ButtonGroup::flatten (
[ boolean $recreateAppearanceIfNeedAppearancesIsSet = false ]
): void

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

Throws SetaPDF_Exception_NotImplemented

getButtons()

Get all buttons of the button group.

getDefaultButton()

getDefaultValue()

public SetaPDF_FormFiller_Field_ButtonGroup::getDefaultValue (
[ string $encoding = 'UTF-8' ]
): null|string

Returns the default value of the button group.

This value is used if the form is reset

Parameters
$encoding : string
 
See

getFields()

getName()

getNoExport()

public SetaPDF_FormFiller_Field_ButtonGroup::getNoExport (
void
): boolean|null

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()

getQualifiedName()

Returns the qualified name.

getTooltip()

public SetaPDF_FormFiller_Field_ButtonGroup::getTooltip (
[ string $encoding = 'UTF-8' ]
): bool|string|null

Get the tooltip value.

Parameters
$encoding : string
 

getValue()

public SetaPDF_FormFiller_Field_ButtonGroup::getValue (
void
): string|null

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

isReadOnly()

public SetaPDF_FormFiller_Field_ButtonGroup::isReadOnly (
void
): boolean|null

Checks if the button group is marked as read-only.

isRequired()

public SetaPDF_FormFiller_Field_ButtonGroup::isRequired (
void
): boolean|null

Checks if the button group is marked as required.

isSetValueActive()

Checks if a setValue operation is active.

onFieldDeleted()

Is called when a button in this group is deleted.

Parameters
$button : SetaPDF_FormFiller_Field_Button
 

setDefaultValue()

public SetaPDF_FormFiller_Field_ButtonGroup::setDefaultValue (
string|null|SetaPDF_FormFiller_Field_Button $value [, string $encoding = 'UTF-8' ]
): void

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()

public SetaPDF_FormFiller_Field_ButtonGroup::setNoExport (
[ boolean $noExport = true ]
): void

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
 

setReadOnly()

public SetaPDF_FormFiller_Field_ButtonGroup::setReadOnly (
[ boolean $readOnly = true ]
): void

Sets the button group to read-only or not.

Parameters
$readOnly : boolean
 

setRequired()

public SetaPDF_FormFiller_Field_ButtonGroup::setRequired (
[ boolean $required = true ]
): void

Sets the button group to be required or not.

Parameters
$required : boolean
 

setTooltip()

public SetaPDF_FormFiller_Field_ButtonGroup::setTooltip (
string|false $value [, string $encoding = 'UTF-8' ]
): void

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

Throws SetaPDF_FormFiller_Field_Exception