Class opIF
Extends
BaseArray.
A class represent: {#if}.
Defined in: jtemplates.js.
Constructor Attributes | Constructor Name and Description |
---|---|
opIF(par, templ)
Create a new conditional node.
|
Method Attributes | Method Name and Description |
---|---|
addCond(oper)
Add condition
|
|
get(d, param, element, deep)
Process node depend on conditional and get the html string.
|
|
Get a parent node.
|
|
push(e)
Add node 'e' to array.
|
|
Switch to else
|
Class Detail
opIF(par, templ)
Create a new conditional node.
- Parameters:
- {object} par
- parent node
- {Template} templ
- template
Method Detail
addCond(oper)
Add condition
- Parameters:
- {string} oper
- content of operator {#..}
{String}
get(d, param, element, deep)
Process node depend on conditional and get the html string.
- Parameters:
- {object} d
- data
- {object} param
- parameters
- {Element} element
- a HTML element
- {Number} deep
- Returns:
- {String}
{BaseNode}
getParent()
Get a parent node.
- Returns:
- {BaseNode}
push(e)
Add node 'e' to array.
- Parameters:
- {BaseNode} e
- a node
switchToElse()
Switch to else