Class YAHOO.widget.HTMLNode

Object
   |
   +--YAHOO.widget.Node
         |
         +--YAHOO.widget.HTMLNode

class YAHOO.widget.HTMLNode

Field Summary [top]

string content
The HTML content to use for this node's display 
string contentElId
The generated id that will contain the data passed in by the implementer. 
string contentStyle
The CSS class for the html content container. 

Constructor Summary [top]

YAHOO.widget.HTMLNode
This implementation takes either a string or object for the oData argument. 

Method Summary [top]

HTMLElement getContentEl ()
Returns the outer html element for this node's content 
string getNodeHtml ()
Get the markup for the node. 
void initContent (oData, <boolean> hasIcon)
Sets up the node label 
string toString ()
toString 

Field Detail [top]

content

string   content
The HTML content to use for this node's display

contentElId

string   contentElId
The generated id that will contain the data passed in by the implementer.

contentStyle

string   contentStyle
The CSS class for the html content container. Defaults to ygtvhtml, but can be overridden to provide a custom presentation for a specific node.

Constructor Detail [top]

YAHOO.widget.HTMLNode

YAHOO.widget.HTMLNode ()
This implementation takes either a string or object for the oData argument. If is it a string, we will use it for the display of this node (and it can contain any html code). If the parameter is an object, we look for a parameter called "html" that will be used for this node's display.
Parameters:
oData - {object} a string or object containing the data that will be used to render this node
oParent - {YAHOO.widget.Node} this node's parent node
expanded - {boolean} the initial expanded/collapsed state
hasIcon - {boolean} specifies whether or not leaf nodes should have an icon

Method Detail [top]

getContentEl

HTMLElement getContentEl ()
Returns the outer html element for this node's content
Returns:
the element

getNodeHtml

string getNodeHtml ()
Get the markup for the node. This is designed to be overrided so that we can support different types of nodes.
Returns:
The HTML that will render this node.

initContent

void initContent (oData, <boolean> hasIcon)
Sets up the node label
Parameters:
hasIcon - determines if the node will be rendered with an icon or not
An - html string or object containing an html property

toString

string toString ()
toString
Returns:
string representation of the node