class RuleAction

This class allows the storage and retrieval of the attributes of a action of a business rule.

Actions are the functional consequences of condition evaluation. If a rule condition is met, the corresponding actions are executed.

Actions are represented by setting attributes on data item, by displaying warning or error messages or by showing/hiding structural elements of the simulation page.

Properties

private int $id
private string $name
private string $target
private int $data
private int $datagroup
private string $step
private string $panel
private string $fieldset
private string $column
private string $fieldrow
private string $field
private string $blockinfo
private string $chapter
private string $section
private string $prenote
private string $postnote
private string $action
private string $footnote
private string $choice
private string $value

Methods

void
__construct(int $id, string $name)

Constructor of class RuleAction

int
getId()

Returns the ID of this action

string
getName()

Returns the name of this action

void
setName(string $name)

Sets the name of this action

string
getTarget()

Returns the target of this action

void
setTarget(string $target)

Sets the target of this action

int
getData()

Returns the ID of the target data item of this action

void
setData(int $data)

Sets the ID of the target data item of this action

int
getDatagroup()

Returns the ID of the target data group of this action

void
setDatagroup(int $datagroup)

Sets the ID of the target data group of this action

string
getStep()

Returns the ID of the target step of this action

void
setStep(string $step)

Sets the ID of the target step of this action

string
getPanel()

Returns the ID of the target panel of this action

void
setPanel(string $panel)

Sets the ID of the target panel of this action

string
getFieldset()

Returns the ID of the target field set of this action

void
setFieldset(string $fieldset)

Sets the ID of the target field set of this action

string
getColumn()

Returns the ID of the target column of this action

void
setColumn(string $column)

Sets the ID of the target column of this action

string
getFieldrow()

Returns the ID of the target field row of this action

void
setFieldrow(string $fieldrow)

Sets the ID of the target field row of this action

string
getField()

Returns the position of the target field of this action

void
setField(string $field)

Sets the position of the target field of this action

string
getBlockinfo()

Returns the ID of the target block of info of this action

void
setBlockinfo(string $blockinfo)

Sets the ID of the target block of info of this action

string
getChapter()

Returns the ID of the target chapter of this action

void
setChapter(string $chapter)

Sets the ID of the target chapter of this action

string
getSection()

Returns the ID of the target section of this action

void
setSection(string $section)

Sets the ID of the target section of this action

string
getPrenote()

Returns the position of the field to which the target note of this action is attached

void
setPrenote(string $prenote)

Sets the position of the field to which the target note of this action is attached

string
getPostnote()

Returns the position of the field to which the target note of this action is attached

void
setPostnote(string $postnote)

Sets the position of the field to which the target note of this action is attached

string
getAction()

Returns the name of the target action button of this action

void
setAction(string $action)

Sets the name of the target action button of this action

string
getFootnote()

Returns the ID of the target footnote of this action

void
setFootnote(string $footnote)

Sets the ID of the target footnote of this action

string
getChoice()

Returns the ID of the target choice of this action

void
setChoice(string $choice)

Sets the ID of the target choice of this action

string
getTargetId()

Returns the target ID of this action

string
getValue()

Returns the value or message of this action

void
setValue(string $value)

Sets the value or message of this action

Details

at line 211
void __construct(int $id, string $name)

Constructor of class RuleAction

Parameters

int $id The ID of this action
string $name The name of this action

Return Value

void

at line 223
int getId()

Returns the ID of this action

Return Value

int the The ID of this action

at line 243
string getName()

Returns the name of this action

The possible values are:

  • notifyError: allows to define an error message associated with a data, a data group or all the data
  • notifyWarning: allows to a warning message associated with a data item, data group, or all data. Unlike the error message, the warning message does not block the progress of the simulation
  • hideObject: allows to hide an element of the simulation form
  • showObject: allows you to show (display) an element of the simulation form
  • setAttribute: allows to assign a value or the result of the evaluation of an expression to the content of a data item or to its default value, its minimum or maximum value, or to define the field of a data source feeding the data.
  • unsetAttribute: deletes the contents of a data item. The data becomes "not filled".

Return Value

string the value The name of this action

at line 264
void setName(string $name)

Sets the name of this action

The possible values are:

  • notifyError: allows to define an error message associated with a data, a data group or all the data
  • notifyWarning: allows to a warning message associated with a data item, data group, or all data. Unlike the error message, the warning message does not block the progress of the simulation
  • hideObject: allows to hide an element of the simulation form
  • showObject: allows you to show (display) an element of the simulation form
  • setAttribute: allows to assign a value or the result of the evaluation of an expression to the content of a data item or to its default value, its minimum or maximum value, or to define the field of a data source feeding the data.
  • unsetAttribute: deletes the contents of a data item. The data becomes "not filled".

Parameters

string $name The name of this action

Return Value

void

at line 277
string getTarget()

Returns the target of this action

The possible values are: 'data', 'datagroup', 'dataset', 'step', 'panel', 'fieldset', 'fieldrow', 'field', 'blockinfo', 'chapter', 'section', 'prenote', 'postnote', 'action', 'footnote', 'choice', 'content', 'min', 'max', 'index' or 'default'

Return Value

string the The target of this action

at line 291
void setTarget(string $target)

Sets the target of this action

The possible values are: 'data', 'datagroup', 'dataset', 'step', 'panel', 'fieldset', 'fieldrow', 'field', 'blockinfo', 'chapter', 'section', 'prenote', 'postnote', 'action', 'footnote', 'choice', 'content', 'min', 'max', 'index' or 'default'

Parameters

string $target The target of this action

Return Value

void

at line 304
int getData()

Returns the ID of the target data item of this action

Available if target is equal to 'data'

Return Value

int the The ID of the target data item

at line 316
void setData(int $data)

Sets the ID of the target data item of this action

Parameters

int $data The ID of the target data item

Return Value

void

at line 329
int getDatagroup()

Returns the ID of the target data group of this action

Available if target is equal to 'datagroup'

Return Value

int The ID of the target data group

at line 341
void setDatagroup(int $datagroup)

Sets the ID of the target data group of this action

Parameters

int $datagroup The ID of the target data group

Return Value

void

at line 354
string getStep()

Returns the ID of the target step of this action

Available if target is equal to 'step'

Return Value

string The ID of the target step

at line 366
void setStep(string $step)

Sets the ID of the target step of this action

Parameters

string $step The ID of the target step

Return Value

void

at line 379
string getPanel()

Returns the ID of the target panel of this action

Available if target is equal to 'panel'

Return Value

string The ID of the target panel

at line 391
void setPanel(string $panel)

Sets the ID of the target panel of this action

Parameters

string $panel The ID of the target panel

Return Value

void

at line 404
string getFieldset()

Returns the ID of the target field set of this action

Available if target is equal to 'fieldset'

Return Value

string The ID of the target field set

at line 416
void setFieldset(string $fieldset)

Sets the ID of the target field set of this action

Parameters

string $fieldset The ID of the target field set

Return Value

void

at line 429
string getColumn()

Returns the ID of the target column of this action

Available if target is equal to 'column'

Return Value

string The ID of the target column

at line 441
void setColumn(string $column)

Sets the ID of the target column of this action

Parameters

string $column The ID of the target column

Return Value

void

at line 454
string getFieldrow()

Returns the ID of the target field row of this action

Available if target is equal to 'fieldrow'

Return Value

string The ID of the target field row

at line 466
void setFieldrow(string $fieldrow)

Sets the ID of the target field row of this action

Parameters

string $fieldrow The ID of the target field row

Return Value

void

at line 479
string getField()

Returns the position of the target field of this action

Available if target is equal to 'field'

Return Value

string The poistion of the target field

at line 491
void setField(string $field)

Sets the position of the target field of this action

Parameters

string $field The position of the target field

Return Value

void

at line 504
string getBlockinfo()

Returns the ID of the target block of info of this action

Available if target is equal to 'blockinfo'

Return Value

string The ID of the target block of info

at line 516
void setBlockinfo(string $blockinfo)

Sets the ID of the target block of info of this action

Parameters

string $blockinfo The ID of the target block of info

Return Value

void

at line 529
string getChapter()

Returns the ID of the target chapter of this action

Available if target is equal to 'chapter'

Return Value

string The ID of the target chapter

at line 541
void setChapter(string $chapter)

Sets the ID of the target chapter of this action

Parameters

string $chapter The ID of the target chapter

Return Value

void

at line 554
string getSection()

Returns the ID of the target section of this action

Available if target is equal to 'section'

Return Value

string The ID of the target section

at line 566
void setSection(string $section)

Sets the ID of the target section of this action

Parameters

string $section The ID of the target section

Return Value

void

at line 579
string getPrenote()

Returns the position of the field to which the target note of this action is attached

Available if target is equal to 'prenote'

Return Value

string The position of the field

at line 591
void setPrenote(string $prenote)

Sets the position of the field to which the target note of this action is attached

Parameters

string $prenote The position of the field

Return Value

void

at line 604
string getPostnote()

Returns the position of the field to which the target note of this action is attached

Available if target is equal to 'postnote'

Return Value

string The position of the field

at line 616
void setPostnote(string $postnote)

Sets the position of the field to which the target note of this action is attached

Parameters

string $postnote The position of the field

Return Value

void

at line 629
string getAction()

Returns the name of the target action button of this action

Available if target is equal to 'action'

Return Value

string The name of the target action button

at line 641
void setAction(string $action)

Sets the name of the target action button of this action

Parameters

string $action The name of the target action button

Return Value

void

at line 654
string getFootnote()

Returns the ID of the target footnote of this action

Available if target is equal to 'footnote'

Return Value

string The ID of the target footnote

at line 666
void setFootnote(string $footnote)

Sets the ID of the target footnote of this action

Parameters

string $footnote The ID of the target footnote

Return Value

void

at line 679
string getChoice()

Returns the ID of the target choice of this action

Available if target is equal to 'choice'

Return Value

string The ID of the target choice

at line 691
void setChoice(string $choice)

Sets the ID of the target choice of this action

Parameters

string $choice The ID of the target choice

Return Value

void

at line 702
string getTargetId()

Returns the target ID of this action

Return Value

string The target ID

at line 743
string getValue()

Returns the value or message of this action

Available if name is equal to 'notifyWarning', 'notifyError' or 'setAttribute'

Return Value

string The value or message

at line 755
void setValue(string $value)

Sets the value or message of this action

Parameters

string $value The value or message

Return Value

void