Class: I2CE DisplayData: Difference between revisions

From IHRIS Wiki
No edit summary
No edit summary
Line 3: Line 3:
*Definition in [[#modules/TemplateData/modules/DisplayData/I2CE_DisplayData.php|modules/TemplateData/modules/DisplayData/I2CE_DisplayData.php]]
*Definition in [[#modules/TemplateData/modules/DisplayData/I2CE_DisplayData.php|modules/TemplateData/modules/DisplayData/I2CE_DisplayData.php]]
=modules/TemplateData/modules/DisplayData/I2CE_DisplayData.php=
=modules/TemplateData/modules/DisplayData/I2CE_DisplayData.php=
This article desrcibes the class '''I2CE_DisplayData'''which extends the class [[Class: I2CE_Module | I2CE_Module]]
This article desrcibes the class '''I2CE_DisplayData''' which extends the class [[Class: I2CE_Module | I2CE_Module]]
It is contained in the module [[iHRIS Module List#template-data|template-data]] in the package [https://launchpad.net/i2ce I2CE]
It is contained in the module [[iHRIS Module List#template-data|template-data]] in the package [https://launchpad.net/i2ce I2CE]
The class is defined in the file: [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.0-release/files/head:modules/TemplateData/modules/DisplayData/I2CE_DisplayData.php modules/TemplateData/modules/DisplayData/I2CE_DisplayData.php]
 
The class is defined in the file: [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.0-release/files/head:/modules/TemplateData/modules/DisplayData/I2CE_DisplayData.php modules/TemplateData/modules/DisplayData/I2CE_DisplayData.php]
 
@subpackage Core
@subpackage Core
@author Carl Leitner <litlfred@ibiblio.org>
@author Carl Leitner <litlfred@ibiblio.org>
@version 2.1
@version 2.1
@access public
@access public
I2CE_DisplayData
I2CE_DisplayData
@todo Better documentation
@todo Better documentation
@package I2CE
@package I2CE
==Methods==
==Methods==
Line 89: Line 97:
This method is inherited from [[Class: I2CE_Fuzzy#userMessage() | I2CE_Fuzzy->userMessage()]]
This method is inherited from [[Class: I2CE_Fuzzy#userMessage() | I2CE_Fuzzy->userMessage()]]
=modules/TemplateData/modules/DisplayData/I2CE_DisplayData.php=
=modules/TemplateData/modules/DisplayData/I2CE_DisplayData.php=
This article desrcibes the class '''I2CE_DisplayData'''which extends the class [[Class: I2CE_Module | I2CE_Module]]
This article desrcibes the class '''I2CE_DisplayData''' which extends the class [[Class: I2CE_Module | I2CE_Module]]
It is contained in the module [[iHRIS Module List#template-data|template-data]] in the package [https://launchpad.net/i2ce I2CE]
It is contained in the module [[iHRIS Module List#template-data|template-data]] in the package [https://launchpad.net/i2ce I2CE]
The class is defined in the file: [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.0-release/files/head:modules/TemplateData/modules/DisplayData/I2CE_DisplayData.php modules/TemplateData/modules/DisplayData/I2CE_DisplayData.php]
 
The class is defined in the file: [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.0-release/files/head:/modules/TemplateData/modules/DisplayData/I2CE_DisplayData.php modules/TemplateData/modules/DisplayData/I2CE_DisplayData.php]
 
@subpackage Core
@subpackage Core
@author Carl Leitner <litlfred@ibiblio.org>
@author Carl Leitner <litlfred@ibiblio.org>
@version 2.1
@version 2.1
@access public
@access public
I2CE_DisplayData
I2CE_DisplayData
@todo Better documentation
@todo Better documentation
@package I2CE
@package I2CE
==Methods==
==Methods==

Revision as of 21:19, 16 October 2009

The class I2CE_DisplayData contains 2 definitions:

modules/TemplateData/modules/DisplayData/I2CE_DisplayData.php

This article desrcibes the class I2CE_DisplayData which extends the class I2CE_Module It is contained in the module template-data in the package I2CE

The class is defined in the file: modules/TemplateData/modules/DisplayData/I2CE_DisplayData.php

@subpackage Core

@author Carl Leitner <litlfred@ibiblio.org>

@version 2.1

@access public

I2CE_DisplayData

@todo Better documentation

@package I2CE

Methods

getHooks()

  • Signature: static public function getHooks()

getMethods()

  • Signature: static public function getMethods()

processDisplay()

Process all display elements

This will go through the entire {@link displayData} array to replace any elements on the page that match the given name. Multiple matches will cycle through the values in the displayData array. If the element is an anchor tag then the value will be appended as name/value pairs to the href attribute.

  • Signature: public function processDisplay($page)

Parameters:

  • $page

processDisplayValue()

  • Signature: static public function processDisplayValue($template,$node,$value,$name_set)

Parameters:

  • $template
  • $node
  • $value
  • $name_set
    • Default Value: true

selectOptions()

  • Signature: static public function selectOptions($template,$node,$selected)

Parameters:

  • $template
  • $node
  • $selected

selectOptionsImmediate()

Selects options

  • Signature: public function selectOptionsImmediate($template,$name,$selected,$node)

Parameters:

  • $template
  • string $name
    The name we are looking for
  • mixed $selected
    String or array of string, The selected values.
  • domnode $node
    Defaults to null meaning the whole page. Data is relative to this node
    • Default Value: null

setDisplayData()

Add a display element to the page.

Mutiple entries with the same field name will be appended to an array so that multiple matches can be handled in order.

  • Signature: public function setDisplayData($template,$field,$value,$node)

Parameters:

  • $template
  • string $field
    The name attribute to match.
  • string $value
    The value to replace the element with.
  • domnode $node
    Defaults to null meaning the whole page. Data is relative to this node
    • Default Value: null

setDisplayDataImmediate()

Process processes display data immediately.

Mutiple entries with the same field name will be appended to an array so that multiple matches can be handled in order.

  • Signature: public function setDisplayDataImmediate($template,$name,$value,$node)

Parameters:

  • $template
  • string $name
    The name attribute to match.
  • string $value
    The value to replace the element with.
  • domnode $node
    Defaults to null meaning the whole page. Data is relative to this node
    • Default Value: null

Inherited Fuzzy Methods

launchBackgroundProcess()

This method is inherited from I2CE_Module->launchBackgroundProcess()

launchBackgroundPHPScript()

This method is inherited from I2CE_Module->launchBackgroundPHPScript()

launchBackgroundPage()

This method is inherited from I2CE_Module->launchBackgroundPage()

userMessage()

This method is inherited from I2CE_Fuzzy->userMessage()

modules/TemplateData/modules/DisplayData/I2CE_DisplayData.php

This article desrcibes the class I2CE_DisplayData which extends the class I2CE_Module It is contained in the module template-data in the package I2CE

The class is defined in the file: modules/TemplateData/modules/DisplayData/I2CE_DisplayData.php

@subpackage Core

@author Carl Leitner <litlfred@ibiblio.org>

@version 2.1

@access public

I2CE_DisplayData

@todo Better documentation

@package I2CE

Methods

getHooks()

  • Signature: static public function getHooks()

getMethods()

  • Signature: static public function getMethods()

processDisplay()

Process all display elements

This will go through the entire {@link displayData} array to replace any elements on the page that match the given name. Multiple matches will cycle through the values in the displayData array. If the element is an anchor tag then the value will be appended as name/value pairs to the href attribute.

  • Signature: public function processDisplay($page)

Parameters:

  • $page

processDisplayValue()

  • Signature: static public function processDisplayValue($template,$node,$value,$name_set)

Parameters:

  • $template
  • $node
  • $value
  • $name_set
    • Default Value: true

selectOptions()

  • Signature: static public function selectOptions($template,$node,$selected)

Parameters:

  • $template
  • $node
  • $selected

selectOptionsImmediate()

Selects options

  • Signature: public function selectOptionsImmediate($template,$name,$selected,$node)

Parameters:

  • $template
  • string $name
    The name we are looking for
  • mixed $selected
    String or array of string, The selected values.
  • domnode $node
    Defaults to null meaning the whole page. Data is relative to this node
    • Default Value: null

setDisplayData()

Add a display element to the page.

Mutiple entries with the same field name will be appended to an array so that multiple matches can be handled in order.

  • Signature: public function setDisplayData($template,$field,$value,$node)

Parameters:

  • $template
  • string $field
    The name attribute to match.
  • string $value
    The value to replace the element with.
  • domnode $node
    Defaults to null meaning the whole page. Data is relative to this node
    • Default Value: null

setDisplayDataImmediate()

Process processes display data immediately.

Mutiple entries with the same field name will be appended to an array so that multiple matches can be handled in order.

  • Signature: public function setDisplayDataImmediate($template,$name,$value,$node)

Parameters:

  • $template
  • string $name
    The name attribute to match.
  • string $value
    The value to replace the element with.
  • domnode $node
    Defaults to null meaning the whole page. Data is relative to this node
    • Default Value: null

Inherited Fuzzy Methods

launchBackgroundProcess()

This method is inherited from I2CE_Module->launchBackgroundProcess()

launchBackgroundPHPScript()

This method is inherited from I2CE_Module->launchBackgroundPHPScript()

launchBackgroundPage()

This method is inherited from I2CE_Module->launchBackgroundPage()

userMessage()

This method is inherited from I2CE_Fuzzy->userMessage()