Constructor
new ConditionService(params)
Parameters:
- Source:
Extends
Methods
(async) checkConditions(tile) → {Promise.<boolean>}
Parameters:
Name |
Type |
Description |
tile |
Object
|
Properties
Name |
Type |
Attributes |
Description |
conditions |
Array
|
|
|
hotspotAnchor |
string
|
<optional>
|
|
|
- Source:
Returns:
-
Type
-
Promise.<boolean>
destroy()
- Source:
getConditions() → {Object}
Deliver API conditions.
- Source:
Returns:
-
Type
-
Object
getURLValue(type) → {string}
Get value from URL.
Parameters:
Name |
Type |
Description |
type |
string
|
|
- Source:
Returns:
-
Type
-
string
removeCondition(name) → {boolean}
Remove API condition.
Parameters:
Name |
Type |
Description |
name |
string
|
|
- Source:
Returns:
-
Type
-
boolean
setCondition(name, value) → {boolean}
Add an API condition.
Parameters:
Name |
Type |
Description |
name |
string
|
|
value |
string
|
boolean
|
|
- Source:
Returns:
-
Type
-
boolean
setConditions(conditions) → {boolean}
Set multiple API conditions.
Parameters:
Name |
Type |
Description |
conditions |
Object
|
|
- Source:
Returns:
-
Type
-
boolean
Transforms a normalized boolean formula into conditions.
Parameters:
Name |
Type |
Attributes |
Default |
Description |
formula |
Array
|
|
|
|
depth |
number
|
<optional>
|
0
|
|
- Source:
Returns:
-
Type
-
Array.<Array.<Help4.service.ConditionService.Condition>>
|
null
Transforms conditions into a normalized boolean formula.
Parameters:
- Source:
Returns:
-
Type
-
Array
validateCondition(condition, hotspotAnchor) → {boolean|Promise.<boolean>}
Parameters:
- Source:
Returns:
-
Type
-
boolean
|
Promise.<boolean>
Type Definitions
Condition
Type:
Properties:
Name |
Type |
Description |
c |
string
|
condition name |
v |
string
|
boolean
|
condition value |
o |
string
|
condition operator |
subtype |
string
|
condition subtype |
anchor |
*
|
??? |
- Source:
ConditionType
Type:
Properties:
Name |
Type |
Description |
element |
'system_element'
|
|
url |
'system_url'
|
|
- Source:
Params
Type:
- Source: