guava
[ class tree: guava ] [ index: guava ] [ all elements ]

Class: View

Source Location: /guava/trunk/includes/view.inc.php

Class Overview


View is a controller for part of an application. It receives events from guava and decices what to do with them.


Author(s):

Methods


Child classes:

ChatConfigureView
View is a controller for part of an application. It receives events from guava and decices what to do with them.
ChatChatView
View is a controller for part of an application. It receives events from guava and decices what to do with them.
MonitorConfigurationView
View is a controller for part of an application. It receives events from guava and decices what to do with them.
MonitorHomeView
View is a controller for part of an application. It receives events from guava and decices what to do with them.

Class Details

[line 13]
View is a controller for part of an application. It receives events from guava and decices what to do with them.



Tags:

abstract:  


[ Top ]


Class Methods


constructor __construct [line 33]

View __construct( string $name)

You must call the constructor to initialize the sidenav variable.



Tags:

access:  public


Overridden in child classes as:

ChatConfigureView::__construct()
ChatChatView::__construct()
MonitorConfigurationView::__construct()
MonitorHomeView::__construct()

Parameters:

string   $name   The name of this view, used for identification for AJAX targets.

[ Top ]

method addMenuItem [line 310]

void addMenuItem( mixed $text, mixed $command)



Tags:

access:  protected


[ Top ]

method close [line 60]

void close( )

Must be provided by derived classes. This method is called whenever the user moves away from this view. You should clean up any variables or store them in QOLT to reduce session memory loadtime.



Tags:

access:  public
abstract:  


Overridden in child classes as:

ChatConfigureView::close()
ChatChatView::close()
MonitorConfigurationView::close()
MonitorHomeView::close()

[ Top ]

method Disable [line 38]

void Disable( )



Tags:

access:  protected


[ Top ]

method disableRefresh [line 377]

boolean disableRefresh( )

Disables the view's refresh.



Tags:

return:  Successful or not. (Will currently always return true)
access:  public


[ Top ]

method enableRefresh [line 356]

boolean enableRefresh( [int $refreshTimer = 5])

Enables this view's refresh and sets it's loop timer minimum. If processing during the loop takes longer than the refreshTimer, the framework will dynamically size the window.



Tags:

return:  Successful or not.
access:  public


Parameters:

int   $refreshTimer   The time (in seconds) that the framework should at least attempt communication

[ Top ]

method getRefreshTimer [line 393]

int getRefreshTimer( )

This function will tell you if refresh is active, and what the base timer is set at.



Tags:

return:  The refresh timer in seconds. If it is 0, then refresh is not enabled.
access:  public


[ Top ]

method getSideNav [line 203]

NavNode getSideNav( [string $name = NULL])

Returns the top NavNode object for the sidenav requested or all NavNodes if no sidenav is requested.



Tags:

return:  If $name is not NULL, returns the NavNode that represents the top level of the side nav. Otherwise, returns an array of sidenav nodes.
access:  public


Parameters:

string   $name   The name of the side nav you want the top level NavNode for. This can be NULL.

[ Top ]

method init [line 51]

void init( )

Must be provided by derived classes. This method is called whenever the user switches to this view.



Tags:

access:  public
abstract:  


Overridden in child classes as:

ChatConfigureView::init()
ChatChatView::init()
MonitorConfigurationView::init()
MonitorHomeView::init()

[ Top ]

method isDisabled [line 42]

void isDisabled( )



Tags:

access:  public


[ Top ]

method isSideNavEnabled [line 170]

boolean isSideNavEnabled( )

Ask the view if the side nav is enabled to be rendered.



Tags:

return:  True if sidenav is enabled, false otherwise.
access:  public


[ Top ]

method menuCommand [line 254]

void menuCommand( string $command)

Need to declare in derived classes. This method is called whenever a menu option is selected.



Tags:

access:  public
abstract:  


Overridden in child classes as:

ChatConfigureView::menuCommand()
ChatChatView::menuCommand()
MonitorConfigurationView::menuCommand()
MonitorHomeView::menuCommand()

Parameters:

string   $command   The identifier of the menu option selected.

[ Top ]

method menuCommandSelect [line 263]

boolean menuCommandSelect( string $command)

Call this to tell the menu to select an option. This should be called in your menuCommand method.



Tags:

return:  If the operation succeeded or not.
access:  public


Parameters:

string   $command   The name of the command to select inside the menu

[ Top ]

method menuListen [line 294]

boolean menuListen( mixed $guavaObject, [mixed $parameterList = null], string $text, string $command)

Adds a menu item to the menu bar.



Tags:

return:  False if the command already exists in the menu.
access:  public


Parameters:

string   $text   The text to show for this menu option
string   $command   The command to associate with this menu option.

[ Top ]

method menuRender [line 326]

void menuRender( )

Called by the framework to render this view's menu.



Tags:

access:  public


[ Top ]

method printFooter [line 443]

void printFooter( )



Tags:

access:  public


[ Top ]

method printHeader [line 410]

void printHeader( )



Tags:

access:  public


[ Top ]

method printTarget [line 143]

void printTarget( string $name)

Prints the target into the output buffer



Tags:

access:  public


Parameters:

string   $name   The name of the target

[ Top ]

method refresh [line 68]

void refresh( )

Must be provided by derived classes. This method is called whenever the page is refreshed by browser refresh or by AJAX calls.



Tags:

access:  public
abstract:  


Overridden in child classes as:

ChatConfigureView::refresh()
ChatChatView::refresh()
MonitorConfigurationView::refresh()
MonitorHomeView::refresh()

[ Top ]

method removeTarget [line 126]

void removeTarget( string $name)

Removes the target from this view's target collection, specified by name.



Tags:

access:  public


Parameters:

string   $name   The name of the target

[ Top ]

method removeTargets [line 134]

void removeTargets( )

Removes all targets from the view's target collection.



Tags:

access:  public


[ Top ]

method render [line 74]

void render( )

Must be provided by derived classes. This method is called whenever the view is asked to render into the main view frame.



Tags:

access:  public
abstract:  


Overridden in child classes as:

ChatConfigureView::render()
ChatChatView::render()
MonitorConfigurationView::render()
MonitorHomeView::render()

[ Top ]

method sendTargets [line 86]

void sendTargets( DOMDocument $dom, DOMNode $domRoot)

Called by AJAX requests to send the targets inside this view.

If your derived view has containers or other objects with a sendTargets method and you want it to refresh along with this view, you need to override this method, and call your container/component object's send targets, and then call this parent method.




Tags:

access:  public


Parameters:

DOMDocument   $dom   Represents the DOM Document to attach to
DOMNode   $domRoot   The element to attach our view element new.

[ Top ]

method sideNavCreate [line 186]

boolean sideNavCreate( string $name, NavNode $navNode)

Use to create a top level sidenav.



Tags:

return:  If the operation was successful.
access:  public


Parameters:

string   $name   To identify the sidenav
NavNode   $navNode   A NavNode or a derived class to represent the top level

[ Top ]

method sideNavDestroy [line 228]

boolean sideNavDestroy( string $name)

Destroy the sidenav requested.



Tags:

return:  If the operation succeeded or not.
access:  public


Parameters:

string   $name   The name of the side nav you want to destroy.

[ Top ]

method sideNavDestroyAll [line 243]

boolean sideNavDestroyAll( )

Call if you want to destroy all sidenavs



Tags:

return:  If the operation succeeded
access:  public


[ Top ]

method sideNavEnable [line 156]

void sideNavEnable( [boolean $value = true])

This function sets the sidenav for this view to render or not render.



Tags:

access:  public


Parameters:

boolean   $value   Optional, true means to enable the side nav render. False means to disable.

[ Top ]

method sideNavRender [line 402]

void sideNavRender( )

Called by the framework to render this view's sidenavs.



Tags:

access:  public


[ Top ]

method targetData [line 109]

void targetData( string $name, string $data)

If the target with the name does not exist, it adds it to the target data collection of this view. If it does exist, it will update it's value and update flag.



Tags:

access:  public


Parameters:

string   $name   The name of the target
string   $data   The data of the target (can be html as well)

[ Top ]

method tooltip [line 276]

void tooltip( mixed $header, mixed $text)



Tags:

access:  protected


[ Top ]


Documentation generated on Wed, 21 Dec 2005 14:36:03 -0800 by phpDocumentor 1.3.0RC3