phpDocumentor HTML_TreeMenu
[ class tree: HTML_TreeMenu ] [ index: HTML_TreeMenu ] [ all elements ]

Class: HTML_TreeNode

Source Location: /HTML_TreeMenu-1.1.2/TreeMenu.php

Class HTML_TreeNode

Class Overview

HTML_TreeNode class

This class is supplementary to the above and provides a way to add nodes to the tree. A node can have other nodes added to it.

Located in /HTML_TreeMenu-1.1.2/TreeMenu.php [line 113]



		
				Author(s):
		
		
		API Tags:
Access:  public

Information Tags:

Properties

Methods

[ Top ]
Direct descendents
Child Class Description
Directory Node

[ Top ]
Property Summary
string   $cssClass   The css class for this node
bool   $ensureVisible   Should this node be made visible?
array   $events   Javascript event handlers;
bool   $expanded   Whether this node is expanded or not
string   $icon   The icon for this node.
bool   $isDynamic   Whether this node is dynamic or not
array   $items   Indexed array of subnodes
string   $link   The link for this node.
object   $parent   The parent node. Null if top level
string   $text   The text for this node.

[ Top ]
Method Summary
HTML_TreeNode   HTML_TreeNode()   Constructor
void   &addItem()   Adds a new subnode to this node.
void   setOption()   Allows setting of various parameters after the initial

[ Top ]
Properties
string   $cssClass [line 137]

The css class for this node


[ Top ]
bool   $ensureVisible [line 161]

Should this node be made visible?


[ Top ]
array   $events [line 173]

Javascript event handlers;


[ Top ]
bool   $expanded [line 149]

Whether this node is expanded or not


[ Top ]
string   $icon [line 131]

The icon for this node.


[ Top ]
bool   $isDynamic [line 155]

Whether this node is dynamic or not


[ Top ]
array   $items [line 143]

Indexed array of subnodes


[ Top ]
string   $link [line 125]

The link for this node.


[ Top ]
object   $parent [line 167]

The parent node. Null if top level


[ Top ]
string   $text [line 119]

The text for this node.


[ Top ]
Methods
Constructor HTML_TreeNode  [line 197]

  HTML_TreeNode HTML_TreeNode( [array $options = array()], [array $events = array()]  )

Constructor

Parameters:
array   $options:  An array of options which you can pass to change the way this node looks/acts. This can consist of:
  • text The title of the node, defaults to blank
  • link The link for the node, defaults to blank
  • icon The icon for the node, defaults to blank
  • class The CSS class for this node, defaults to blank
  • expanded The default expanded status of this node, defaults to false This doesn't affect non dynamic presentation types
  • isDynamic If this node is dynamic or not. Only affects certain presentation types.
  • ensureVisible If true this node will be made visible despite the expanded settings, and client side persistence. Will not affect some presentation styles, such as Listbox. Default is false
array   $events:  An array of javascript events and the corresponding event handlers. Additionally to the standard javascript events you can specify handlers for the 'onexpand', 'oncollapse' and 'ontoggle' events which will be fired whenever a node is collapsed and/or expanded.

API Tags:
Access:  public


[ Top ]
addItem  [line 242]

  void &addItem( &$node, object $node  )

Adds a new subnode to this node.

Parameters:
object   $node:  The new node
   &$node: 

API Tags:
Access:  public


[ Top ]
setOption  [line 231]

  void setOption( string $option, string $value  )

Allows setting of various parameters after the initial

constructor call. Possible options you can set are:

  • text
  • link
  • icon
  • cssClass
  • expanded
  • isDynamic
  • ensureVisible
ie The same options as in the constructor

Parameters:
string   $option:  Option to set
string   $value:  Value to set the option to

API Tags:
Access:  public


[ Top ]

Documentation generated on Tue, 24 Oct 2006 09:26:34 -0500 by phpDocumentor 1.3.1