ILIAS  Release_4_0_x_branch Revision 61816
 All Data Structures Namespaces Files Functions Variables Groups Pages
ilPCSection Class Reference

Class ilPCSection. More...

+ Inheritance diagram for ilPCSection:
+ Collaboration diagram for ilPCSection:

Public Member Functions

 init ()
 Init page content component.
 setNode (&$a_node)
 Set node.
 create (&$a_pg_obj, $a_hier_id, $a_pc_id="")
 Create section node in xml.
 setCharacteristic ($a_char)
 Set Characteristic of section.
 getCharacteristic ()
 Get characteristic of section.
- Public Member Functions inherited from ilPageContent
 __construct ($a_dom)
 Constructor.
 getType ()
 Get type of page content.
getNode ()
 Get xml node of page content.
 setHierId ($a_hier_id)
 Set hierarchical ID in xml structure.
 getHierId ()
 Get hierarchical id.
 lookupHierId ()
 Get hierarchical id from dom.
 readHierId ()
 Read PC Id.
 setPcId ($a_pcid)
 Set PC Id.
 getPCId ()
 Get PC Id.
 readPCId ()
 Read PC Id.
 isGreaterHierId ($a, $b)
 Check whether Hier ID $a is greater than Hier ID $b.
 setEnabled ($value)
 Set Enabled value for page content component.
 enable ()
 Enable page content.
 disable ()
 Disable page content.
 isEnabled ()
 Check whether page content is enabled.
 createPageContentNode ($a_set_this_node=true)
 Create page content node (always use this method first when adding a new element)

Data Fields

 $dom
 $sec_node
- Data Fields inherited from ilPageContent
 $hier_id
 $node
 $dom

Additional Inherited Members

- Static Public Member Functions inherited from ilPageContent
static incEdId ($ed_id)
 Increases an hierarchical editing id at lowest level (last number)
static decEdId ($ed_id)
 Decreases an hierarchical editing id at lowest level (last number)
static haveSameContainer ($ed_id1, $ed_id2)
 Check, if two ids are in same container.
static sortHierIds ($a_array)
 Sort an array of Hier IDS in ascending order.
- Protected Member Functions inherited from ilPageContent
 setType ($a_type)
 Set Type.

Detailed Description

Class ilPCSection.

Section content object (see ILIAS DTD)

Author
Alex Killing alex..nosp@m.kill.nosp@m.ing@g.nosp@m.mx.d.nosp@m.e
Version
$Id$

Definition at line 36 of file class.ilPCSection.php.

Member Function Documentation

ilPCSection::create ( $a_pg_obj,
  $a_hier_id,
  $a_pc_id = "" 
)

Create section node in xml.

Parameters
object$a_pg_objPage Object
string$a_hier_idHierarchical ID

Definition at line 64 of file class.ilPCSection.php.

References ilPageContent\createPageContentNode(), and IL_INSERT_AFTER.

{
$this->node = $this->createPageContentNode();
$a_pg_obj->insertContent($this, $a_hier_id, IL_INSERT_AFTER, $a_pc_id);
$this->sec_node =& $this->dom->create_element("Section");
$this->sec_node =& $this->node->append_child($this->sec_node);
$this->sec_node->set_attribute("Characteristic", "Block");
}

+ Here is the call graph for this function:

ilPCSection::getCharacteristic ( )

Get characteristic of section.

Returns
string characteristic

Definition at line 98 of file class.ilPCSection.php.

{
if (is_object($this->sec_node))
{
$char = $this->sec_node->get_attribute("Characteristic");
if (substr($char, 0, 4) == "ilc_")
{
$char = substr($char, 4);
}
return $char;
}
}
ilPCSection::init ( )

Init page content component.

Reimplemented from ilPageContent.

Definition at line 44 of file class.ilPCSection.php.

References ilPageContent\setType().

{
$this->setType("sec");
}

+ Here is the call graph for this function:

ilPCSection::setCharacteristic (   $a_char)

Set Characteristic of section.

Parameters
string$a_charCharacteristic

Definition at line 78 of file class.ilPCSection.php.

{
if (!empty($a_char))
{
$this->sec_node->set_attribute("Characteristic", $a_char);
}
else
{
if ($this->sec_node->has_attribute("Characteristic"))
{
$this->sec_node->remove_attribute("Characteristic");
}
}
}
ilPCSection::setNode ( $a_node)

Set node.

Reimplemented from ilPageContent.

Definition at line 52 of file class.ilPCSection.php.

{
parent::setNode($a_node); // this is the PageContent node
$this->sec_node =& $a_node->first_child(); // this is the Section node
}

Field Documentation

ilPCSection::$dom

Definition at line 38 of file class.ilPCSection.php.

ilPCSection::$sec_node

Definition at line 39 of file class.ilPCSection.php.


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