NavXMLModule Class Reference

Produces XML that can be rendered as PR2 navigation. More...

List of all members.

Public Member Functions

 __construct ()
 Create a NavXMLModule to generate the navigation for a page.
 addLinkLevel ($name, $link)
 Add a link/path level to the set of breadcrumbs.
 addTab ($name, $link)
 Add a tab to the current row.
 addTabRow ()
 Finish a row of tabs.
 generateBrowseXML ()
 Generate the Browse XML.
 generateJumpToXML ()
 Generate the Jump-To XML.
 generateSearchXML ()
 Generate the Search XML.
 generateXML ()
 Generate the PR2-ready navigation XML string.


Detailed Description

Produces XML that can be rendered as PR2 navigation.

This class builds the XML that is translated by PR2 to generate all forms of site navigation.

Author:
Jonathan (jwsm@shodor.org)
Date:
Sometime in 05-06

Member Function Documentation

NavXMLModule::addLinkLevel ( name,
link 
)

Add a link/path level to the set of breadcrumbs.

Parameters:
$name [string]: The text to appear for the breadcrumb
$link [string]: The URL link for the breadcrumb

NavXMLModule::addTab ( name,
link 
)

Add a tab to the current row.

Parameters:
$name [string]: The text to appear on the tab
$link [string]: The URL to which the tab should link

NavXMLModule::addTabRow (  ) 

Finish a row of tabs.

Use this function after you have finished adding a row of tabs, having called addTab() to create those tabs.

NavXMLModule::generateBrowseXML (  ) 

Generate the Browse XML.

Returns:
[string]: The section of the XML describing the Browse menu
This function should be overridden in your project's site navigation object (which should extend this class). That child object should return the browse XML specific to your project.

NavXMLModule::generateJumpToXML (  ) 

Generate the Jump-To XML.

Returns:
[string]: The section of the XML describing the Jump-To menu
This function should be overridden in your project's site navigation object (which should extend this class). That child object should return the jump-to XML specific to your project.

NavXMLModule::generateSearchXML (  ) 

Generate the Search XML.

Returns:
[string]: The section of the XML describing the Search menu
This function should be overridden in your project's site navigation object (which should extend this class). That child object should return the search XML specific to your project.

NavXMLModule::generateXML (  ) 

Generate the PR2-ready navigation XML string.

Returns:
[string]: Navigation XML
This function calls generateBrowseXML(), generateJumpToXML(), and generateSearchXML(), as well as fetching the path and tabs XML that has already been generated for this object through calls to addLinkLevel(), addTab(), and addTabRow(). All of this XML is combined and returned by this function.


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

Generated on Wed Nov 24 02:02:27 2010 for Common by  doxygen 1.5.6