[ Index ]

PHP Cross Reference of Akelos Framework

title

Body

[close]

/AkActionView/ -> AkHelperLoader.php (summary)

(no description)

File Size: 219 lines (8 kb)
Included or required: 4 times
Referenced: 0 times
Includes or requires: 1 file
 AkActionView/AkActionViewHelper.php

Defines 1 class

AkHelperLoader:: (13 methods):
  __construct()
  setController()
  setHandler()
  instantiateHelpers()
  instantiateHelpersAsHandlerAttributes()
  getHelpersForMailer()
  _storeInstantiatedHelperNames()
  getInstantiatedHelperNames()
  getHelperNames()
  getDefaultHandlerHelperNames()
  getApplicationHelperNames()
  getPluginHelperNames()
  addPluginHelper()


Class: AkHelperLoader  - X-Ref

Helpers are normally loaded in the context of a controller call, but some
times they might be useful in Mailers, Comand line tools or for unit testing

Some helpers might require information available only on a conroller context
such as current URL, Request and Response information among others.
__construct()   X-Ref
No description

setController(&$ControllerInstance)   X-Ref
No description

setHandler(&$HandlerInstance)   X-Ref
$HandlerInstance is the object where all the helpers will be instantiated as attributes.

Like setController but for Mailers and Testing

instantiateHelpers()   X-Ref
Creates an instance of each available helper and links it into into current handler.

For example, if a helper TextHelper is located into the file text_helper.php.
An instance is created on current controller
at $this->text_helper. This instance is also available on the view by calling $text_helper.

Helpers can be found at lib/AkActionView/helpers (this might change in a future)

Retuns an array with helper_name => HerlperInstace

instantiateHelpersAsHandlerAttributes($helpers = array()   X-Ref
No description

getHelpersForMailer()   X-Ref
Creates an instance of each available helper and links it into into current mailer.

Mailer helpers work as Controller helpers but without the Request context

_storeInstantiatedHelperNames($helpers)   X-Ref
In order to help rendering engines to know which helpers are available
we need to persit them as a static var.


getInstantiatedHelperNames()   X-Ref
Returns an array of helper names like:

array('url_helper', 'prototype_helper')

getHelperNames()   X-Ref
No description

getDefaultHandlerHelperNames()   X-Ref
No description

getApplicationHelperNames()   X-Ref
No description

getPluginHelperNames()   X-Ref
No description

addPluginHelper($helper_name, $options = array()   X-Ref
Used for adding helpers to the base class like those added by the plugins engine.

param: string $helper_name Helper class name like CalendarHelper
param: array $options - path: Path to the helper class, defaults to AK_PLUGINS_DIR/helper_name/lib/helper_name.php



Generated: Mon Oct 27 12:43:49 2008 Cross-referenced by PHPXref 0.6