Public Member Functions | Protected Attributes

ilSubEnabledFormPropertyGUI Class Reference
[Services/Form]

This class represents a property that may include a sub form. More...

Inheritance diagram for ilSubEnabledFormPropertyGUI:
Collaboration diagram for ilSubEnabledFormPropertyGUI:

Public Member Functions

 addSubItem ($a_item)
 Add Subitem.
 getSubItems ()
 Get Subitems.
 setSubformMode ($a_subformmode)
 Set Subform Mode.
 getSubformMode ()
 Get Subform Mode.
 checkSubItemsInput ()
 Check SubItems.
 getSubForm ()
 Get sub form html.

Protected Attributes

 $sub_items = array()
 $subformmode = "bottom"

Detailed Description

This class represents a property that may include a sub form.

Author:
Alex Killing <alex.killing@gmx.de>
Version:
$Id$

Definition at line 31 of file class.ilSubEnabledFormPropertyGUI.php.


Member Function Documentation

ilSubEnabledFormPropertyGUI::addSubItem ( a_item  ) 

Add Subitem.

Parameters:
object $a_item Item

Definition at line 41 of file class.ilSubEnabledFormPropertyGUI.php.

        {
                $this->sub_items[] = $a_item;
        }

ilSubEnabledFormPropertyGUI::checkSubItemsInput (  )  [final]

Check SubItems.

Returns:
boolean Input ok, true/false

Definition at line 81 of file class.ilSubEnabledFormPropertyGUI.php.

References $ok, and getSubItems().

Referenced by ilTextInputGUI::checkInput(), ilTextAreaInputGUI::checkInput(), ilSelectInputGUI::checkInput(), and ilCheckboxInputGUI::checkInput().

        {
                $ok = true;
                foreach($this->getSubItems() as $item)
                {
                        $item_ok = $item->checkInput();
                        if(!$item_ok)
                        {
                                $ok = false;
                        }
                }
                return $ok;
        }

Here is the call graph for this function:

Here is the caller graph for this function:

ilSubEnabledFormPropertyGUI::getSubForm (  )  [final]

Get sub form html.

Reimplemented from ilFormPropertyGUI.

Definition at line 99 of file class.ilSubEnabledFormPropertyGUI.php.

References getSubformMode(), and getSubItems().

        {
                // subitems
                $form = "";
                if (count($this->getSubItems()) > 0)
                {
                        $pf = new ilPropertyFormGUI();
                        $pf->setSubformMode($this->getSubformMode());
                        $pf->setMode("subform");
                        $pf->setItems($this->getSubItems());
                        $form = $pf->getContent();
                }

                return $form;
        }

Here is the call graph for this function:

ilSubEnabledFormPropertyGUI::getSubformMode (  ) 

Get Subform Mode.

("bottom" | "right")

Returns:
string Subform Mode

Reimplemented from ilFormPropertyGUI.

Definition at line 71 of file class.ilSubEnabledFormPropertyGUI.php.

Referenced by getSubForm().

        {
                return $this->subformmode;
        }

Here is the caller graph for this function:

ilSubEnabledFormPropertyGUI::getSubItems (  ) 

Get Subitems.

Returns:
array Array of items

Definition at line 51 of file class.ilSubEnabledFormPropertyGUI.php.

Referenced by checkSubItemsInput(), getSubForm(), and ilCheckboxInputGUI::setValueByArray().

        {
                return $this->sub_items;
        }

Here is the caller graph for this function:

ilSubEnabledFormPropertyGUI::setSubformMode ( a_subformmode  ) 

Set Subform Mode.

("bottom" | "right")

Parameters:
string $a_subformmode Subform Mode

Definition at line 61 of file class.ilSubEnabledFormPropertyGUI.php.

        {
                $this->subformmode = $a_subformmode;
        }


Field Documentation

ilSubEnabledFormPropertyGUI::$sub_items = array() [protected]

Definition at line 33 of file class.ilSubEnabledFormPropertyGUI.php.

ilSubEnabledFormPropertyGUI::$subformmode = "bottom" [protected]

Definition at line 34 of file class.ilSubEnabledFormPropertyGUI.php.


The documentation for this class was generated from the following file: