Detailed reference of prototypes, properties and methods available in the
Javascript environment of your Helma web applications.

Adds useful methods to Helma's built-in HopObject prototype.

To use this optional module, its repository needs to be added to the application, for example by calling app.addRepository('modules/core/HopObject.js')
Methods
HopObject. forEach(callback)
Iterates over each child node of the HopObject.
parameters
Function callback The callback function to be called for each child node. On every call the first argument of this function is set to the current value of the counter variable i.
HopObject. id_macro()
macro returns the id of a HopObject
HopObject. href_macro(param, action)
macro returns the url for any hopobject
parameters
param
action
HopObject. skin_macro(param, name)
macro rendering a skin or displaying its source (param.as == "source")
parameters
param
name
HopObject. switch_macro(param)
this macro renders a text depending on the value of a given property
parameters
param
HopObject. loop_macro(Object)
generic macro that loops over the childobjects and renders a specified skin for each of them
parameters
Object providing the following properties: skin: the skin to render for each item (required) collection: the collection containing the items limit: max. number of items per page (req.data.page determines the page number) sort: property name to use for sorting order: sort order (either "asc" or "desc") itemPrefix: text to prepend to each items skin render itemSuffix: text to append to each items skin render
HopObject. size_macro(param, name)
Render the number of child nodes of the HopObject. Three cases are distinguished which can be customized by setting param.verbose to "true" and defining the corresponding field of the param argument:
  1. param.none - not a single child node
  2. param.one - exactly one child node
  3. param.many - more than one child node
parameters
Object param The default macro parameter
String name The default name for a child node
Fri, 05 Feb 2010 17:40:05 GMT.

core framework

optional modules

java libraries

properties files