HTML_QuickForm2
[ class tree: HTML_QuickForm2 ] [ index: HTML_QuickForm2 ] [ all elements ]

Class: HTML_QuickForm2_Container_Group

Source Location: /HTML_QuickForm2-2.1.0/HTML/QuickForm2/Container/Group.php

Class Overview

HTML_Common2
   |
   --HTML_QuickForm2_Node
      |
      --HTML_QuickForm2_Container
         |
         --HTML_QuickForm2_Container_Group

Base class for QuickForm2 groups of elements


Author(s):

Version:

  • Release: 2.1.0

Variables

Methods


Child classes:

HTML_QuickForm2_Element_Hierselect
Hierarchical select element
HTML_QuickForm2_Element_Date
Class for a group of elements used to input dates (and times).

Inherited Variables

Inherited Methods

Class: HTML_QuickForm2_Container

HTML_QuickForm2_Container::addElement()
Appends an element to the container (possibly creating it first)
HTML_QuickForm2_Container::appendChild()
Appends an element to the container
HTML_QuickForm2_Container::arrayMerge()
Merges two arrays
HTML_QuickForm2_Container::count()
Returns the number of elements in the container
HTML_QuickForm2_Container::getChildValues()
Returns the array containing child elements' values
HTML_QuickForm2_Container::getElementById()
Returns an element if its id is found
HTML_QuickForm2_Container::getElements()
Returns an array of this container's elements
HTML_QuickForm2_Container::getElementsByName()
Returns an array of elements which name corresponds to element
HTML_QuickForm2_Container::getIterator()
Returns a recursive iterator for the container elements
HTML_QuickForm2_Container::getJavascriptTriggers()
HTML_QuickForm2_Container::getJavascriptValue()
Returns Javascript code for getting the element's value
HTML_QuickForm2_Container::getRawValue()
Returns the container's value without filters applied
HTML_QuickForm2_Container::getRecursiveIterator()
Returns a recursive iterator iterator for the container elements
HTML_QuickForm2_Container::getValue()
Returns the container's value, possibly with filters applied
HTML_QuickForm2_Container::insertBefore()
Inserts an element in the container
HTML_QuickForm2_Container::persistentFreeze()
HTML_QuickForm2_Container::prependsName()
Whether container prepends its name to names of contained elements
HTML_QuickForm2_Container::removeChild()
Removes the element from this container
HTML_QuickForm2_Container::render()
Renders the container using the given renderer
HTML_QuickForm2_Container::setName()
HTML_QuickForm2_Container::toggleFrozen()
HTML_QuickForm2_Container::updateValue()
Called when the element needs to update its value from form's data sources
HTML_QuickForm2_Container::validate()
Performs the server-side validation
HTML_QuickForm2_Container::__call()
Appends an element to the container, creating it first
HTML_QuickForm2_Container::__toString()

Class: HTML_QuickForm2_Node

HTML_QuickForm2_Node::__construct()
Class constructor
HTML_QuickForm2_Node::addFilter()
Adds a filter
HTML_QuickForm2_Node::addRecursiveFilter()
Adds a recursive filter
HTML_QuickForm2_Node::addRule()
Adds a validation rule
HTML_QuickForm2_Node::applyFilter()
Helper function for applying filter callback to a value
HTML_QuickForm2_Node::applyFilters()
Applies non-recursive filters on element value
HTML_QuickForm2_Node::createRule()
Creates a validation rule
HTML_QuickForm2_Node::generateId()
Generates an id for the element
HTML_QuickForm2_Node::getContainer()
Returns the element containing current
HTML_QuickForm2_Node::getData()
Returns the element options
HTML_QuickForm2_Node::getDataSources()
Returns the data sources for this element
HTML_QuickForm2_Node::getError()
Returns the error message for the element
HTML_QuickForm2_Node::getId()
Returns the element's id
HTML_QuickForm2_Node::getJavascriptTriggers()
Returns IDs of form fields that should trigger "live" Javascript validation
HTML_QuickForm2_Node::getJavascriptValue()
Returns Javascript code for getting the element's value
HTML_QuickForm2_Node::getLabel()
Returns the element's label(s)
HTML_QuickForm2_Node::getName()
Returns the element's name
HTML_QuickForm2_Node::getRawValue()
Returns the element's value without filters applied
HTML_QuickForm2_Node::getType()
Returns the element's type
HTML_QuickForm2_Node::getValue()
Returns the element's value, possibly with filters applied
HTML_QuickForm2_Node::isRequired()
Checks whether an element is required
HTML_QuickForm2_Node::onAttributeChange()
Intercepts setting 'name' and 'id' attributes
HTML_QuickForm2_Node::persistentFreeze()
Changes the element's persistent freeze behaviour
HTML_QuickForm2_Node::removeRule()
Removes a validation rule
HTML_QuickForm2_Node::render()
Renders the element using the given renderer
HTML_QuickForm2_Node::renderClientRules()
Adds element's client-side validation rules to a builder object
HTML_QuickForm2_Node::setContainer()
Adds the link to the element containing current
HTML_QuickForm2_Node::setError()
Sets the error message to the element
HTML_QuickForm2_Node::setId()
Sets the element's id
HTML_QuickForm2_Node::setLabel()
Sets the element's label(s)
HTML_QuickForm2_Node::setName()
Sets the element's name
HTML_QuickForm2_Node::setValue()
Sets the element's value
HTML_QuickForm2_Node::storeId()
Stores the explicitly given id to prevent duplicate id generation
HTML_QuickForm2_Node::toggleFrozen()
Changes the element's frozen status
HTML_QuickForm2_Node::updateValue()
Called when the element needs to update its value from form's data sources
HTML_QuickForm2_Node::validate()
Performs the server-side validation

Class Details

[line 38]
Base class for QuickForm2 groups of elements


[ Top ]


Class Variables

$name =

[line 46]

Group name If set, group name will be used as prefix for contained element names, like groupname[elementname].
  • Access: protected

Type:   string


[ Top ]

$previousName =

[line 54]

Previous group name Stores the previous group name when the group name is changed.

Used to restore children names if necessary.

  • Access: protected

Type:   string


[ Top ]



Method Detail

appendChild   [line 232]

HTML_QuickForm2_Node appendChild( HTML_QuickForm2_Node $element)

Appends an element to the container

If the element was previously added to the container or to another container, it is first removed there.

  • Return: Added element
  • Throws: HTML_QuickForm2_InvalidArgumentException
  • Access: public

Overrides HTML_QuickForm2_Container::appendChild() (Appends an element to the container)

Parameters:

HTML_QuickForm2_Node   $element   —  Element to add

[ Top ]

getChildValues   [line 66]

void getChildValues( [ $filtered = false])

  • Access: protected

Overrides HTML_QuickForm2_Container::getChildValues() (Returns the array containing child elements' values)

Parameters:

   $filtered   — 

[ Top ]

getName   [line 173]

void getName( )

  • Access: public

Overrides HTML_QuickForm2_Node::getName() (Returns the element's name)
[ Top ]

getSeparator   [line 304]

string|array getSeparator( )

Returns string(s) to separate grouped elements
  • Return: Separator, null if not set
  • Access: public

[ Top ]

getType   [line 56]

void getType( )

  • Access: public

Overridden in child classes as:

HTML_QuickForm2_Element_Hierselect::getType()
HTML_QuickForm2_Element_Date::getType()

Overrides HTML_QuickForm2_Node::getType() (Returns the element's type)
[ Top ]

insertBefore   [line 277]

HTML_QuickForm2_Node insertBefore( HTML_QuickForm2_Node $element, [HTML_QuickForm2_Node $reference = null])

Inserts an element in the container

If the reference object is not given, the element will be appended.

  • Return: Inserted element
  • Access: public

Overrides HTML_QuickForm2_Container::insertBefore() (Inserts an element in the container)

Parameters:

HTML_QuickForm2_Node   $element   —  Element to insert
HTML_QuickForm2_Node   $reference   —  Reference to insert before

[ Top ]

prependsName   [line 61]

void prependsName( )

  • Access: protected

Overrides HTML_QuickForm2_Container::prependsName() (Whether container prepends its name to names of contained elements)
[ Top ]

removeChild   [line 254]

HTML_QuickForm2_Node removeChild( HTML_QuickForm2_Node $element)

Removes the element from this container

If the reference object is not given, the element will be appended.

  • Return: Removed object
  • Access: public

Overrides HTML_QuickForm2_Container::removeChild() (Removes the element from this container)

Parameters:

HTML_QuickForm2_Node   $element   —  Element to remove

[ Top ]

renameChild   [line 197]

HTML_QuickForm2_Node renameChild( HTML_QuickForm2_Node $element)

Prepends group's name to contained element's name

Used when adding an element to the group or changing group's name

  • Access: protected

Parameters:

HTML_QuickForm2_Node   $element   — 

[ Top ]

render   [line 316]

HTML_QuickForm2_Renderer render( HTML_QuickForm2_Renderer $renderer)

Renders the group using the given renderer
  • Access: public

Overridden in child classes as:

HTML_QuickForm2_Element_Hierselect::render()
Renders the hierselect using the given renderer

Overrides HTML_QuickForm2_Container::render() (Renders the container using the given renderer)

Parameters:

HTML_QuickForm2_Renderer   $renderer   — 

[ Top ]

setName   [line 178]

void setName( $name)

  • Access: public

Overridden in child classes as:

HTML_QuickForm2_Element_Hierselect::setName()
Sets the element's name

Overrides HTML_QuickForm2_Container::setName() (parent method not documented)

Parameters:

   $name   — 

[ Top ]

setSeparator   [line 293]

$this setSeparator( string|array $separator)

Sets string(s) to separate grouped elements
  • Access: public

Parameters:

string|array   $separator   —  Use a string for one separator, array for alternating separators

[ Top ]

setValue   [line 89]

void setValue( $value)

  • Access: public

Overridden in child classes as:

HTML_QuickForm2_Element_Hierselect::setValue()
Sets the element's value
HTML_QuickForm2_Element_Date::setValue()
Tries to convert the given value to a usable date before setting the element value

Overrides HTML_QuickForm2_Node::setValue() (Sets the element's value)

Parameters:

   $value   — 

[ Top ]

__toString   [line 327]

void __toString( )

  • Access: public

Overrides HTML_QuickForm2_Container::__toString() (parent method not documented)
[ Top ]


Documentation generated on Wed, 10 Apr 2019 08:56:09 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.