class Step

This class allows the storage and retrieval of the attributes of a simulation step.

Properties

private Simulator $simulator
private int $id
private string $name
private string $label
private string $template
private string $output
private string $description
private bool $dynamic
private array $panels
private array $actions
private Footnotes $footnotes
private bool $displayable

Methods

void
__construct(Simulator $simulator, int $id, string $name, string $label, string $template)

Constructor of class Step

getSimulator()

Returns the Simulator object to which this step belongs

int
getId()

Returns the ID of this step

void
setId(int $id)

Sets the ID of this step

string
getName()

Returns the name of this step

void
setName(string $name)

Sets the name of this step

string
getTemplate()

Returns the name of the twig template that is used to display the simulation form for this step

void
setTemplate(string $template)

Sets the name of the twig template that is used to display the simulation form for this step

string
getOutput()

Returns the output of the result of the execution of the step

void
setOutput(string $output)

Sets the output of the result of the execution of the step

string
getLabel()

Returns the label of this step

void
setLabel(string $label)

Sets the label of this step

string
getDescription()

Returns the description of this step

void
setDescription(string $description)

Sets the description of this step

bool
isDynamic()

Returns the dynamic attribute of this Step object

bool
getDynamic()

Returns the dynamic attribute of this Step object

void
setDynamic(bool $dynamic)

Determines whether this step is dynamic or not

array
getPanels()

Returns the list of panels of this step.

void
setPanels(array $panels)

Sets the list of panels of this step.

void
addPanel(Panel $panel)

Adds a Panel object to the list of panels of this step.

void
removePanel(int $index)

Removes a Panel object from the list of panels of this step.

Panel|null
getPanelById(int $id)

Retrieves an Panel object by its ID in the list of panels of this step

array
getActions()

Returns the list of action buttons of this step.

void
setActions(array $actions)

Sets the list of action buttons of this step.

void
addAction(Action $action)

Adds an Action object to the list of action buttons of this step.

void
removeAction(int $index)

Removes an Action object from the list of action buttons of this step.

Action|null
getActionByName(string $name)

Retrieves an Action object by its name in the list of action buttons of this step

Footnotes
getFootNotes()

Returns the footnotes container of this step

void
setFootNotes(FootNotes $footnotes)

Sets the footnotes container of this step

bool
isDisplayable()

Returns the displayable attribute of this Step object

bool
getDisplayable()

Returns the displayable attribute of this Step object

void
setDisplayable(bool $displayable)

Determines whether this step can be displayed or not

Details

at line 145
void __construct(Simulator $simulator, int $id, string $name, string $label, string $template)

Constructor of class Step

Parameters

Simulator $simulator The Simulator object to which this step belongs
int $id The ID of this step
string $name The name of this step
string $label The label of this step
string $template The twig template that is used to display the simulation form for this step

Return Value

void

at line 160
Simulator getSimulator()

Returns the Simulator object to which this step belongs

Return Value

Simulator The Simulator object

at line 171
int getId()

Returns the ID of this step

Return Value

int The ID of this step

at line 183
void setId(int $id)

Sets the ID of this step

Parameters

int $id The ID of this step

Return Value

void

at line 194
string getName()

Returns the name of this step

Return Value

string the The name of this step

at line 206
void setName(string $name)

Sets the name of this step

Parameters

string $name The name of this step

Return Value

void

at line 217
string getTemplate()

Returns the name of the twig template that is used to display the simulation form for this step

Return Value

string The name of the twig template.

at line 229
void setTemplate(string $template)

Sets the name of the twig template that is used to display the simulation form for this step

Parameters

string $template The name of the twig template.

Return Value

void

at line 247
string getOutput()

Returns the output of the result of the execution of the step

The possible values are:

  • normal: the step is displayed normally.
  • inlinePDF: G6K displays a PDF rendering of the generated page.
  • downloadablePDF: G6K generates a PDF file of the rendering of the page to be downloaded.
  • html: Not implemented

Return Value

string The output of the result

at line 266
void setOutput(string $output)

Sets the output of the result of the execution of the step

The possible values are:

  • normal: the step is displayed normally.
  • inlinePDF: G6K displays a PDF rendering of the generated page.
  • downloadablePDF: G6K generates a PDF file of the rendering of the page to be downloaded.
  • html: Not implemented

Parameters

string $output The output of the result

Return Value

void

at line 277
string getLabel()

Returns the label of this step

Return Value

string The label of this step

at line 289
void setLabel(string $label)

Sets the label of this step

Parameters

string $label The label of this step

Return Value

void

at line 300
string getDescription()

Returns the description of this step

Return Value

string the The description of this step

at line 312
void setDescription(string $description)

Sets the description of this step

Parameters

string $description The description of this step

Return Value

void

at line 325
bool isDynamic()

Returns the dynamic attribute of this Step object

if true, the simulation engine will use Javascript to give interactivity to the simulation for this step

Return Value

bool true if this step is dynamic, false otherwise

at line 338
bool getDynamic()

Returns the dynamic attribute of this Step object

if true, the simulation engine will use Javascript to give interactivity to the simulation for this step

Return Value

bool true if this step is dynamic, false otherwise

at line 352
void setDynamic(bool $dynamic)

Determines whether this step is dynamic or not

if true, the simulation engine will use Javascript to give interactivity to the simulation for this step

Parameters

bool $dynamic true if this step is dynamic, false otherwise

Return Value

void

at line 363
array getPanels()

Returns the list of panels of this step.

Return Value

array The list of panels

at line 375
void setPanels(array $panels)

Sets the list of panels of this step.

Parameters

array $panels The list of panels

Return Value

void

at line 387
void addPanel(Panel $panel)

Adds a Panel object to the list of panels of this step.

Parameters

Panel $panel The Panel object

Return Value

void

at line 399
void removePanel(int $index)

Removes a Panel object from the list of panels of this step.

Parameters

int $index The index of the Panel object in the list of panels

Return Value

void

at line 411
Panel|null getPanelById(int $id)

Retrieves an Panel object by its ID in the list of panels of this step

Parameters

int $id The ID of the panel

Return Value

Panel|null The Panel object

at line 427
array getActions()

Returns the list of action buttons of this step.

Return Value

array The list of action buttons

at line 439
void setActions(array $actions)

Sets the list of action buttons of this step.

Parameters

array $actions The list of action buttons

Return Value

void

at line 451
void addAction(Action $action)

Adds an Action object to the list of action buttons of this step.

Parameters

Action $action The Action object

Return Value

void

at line 463
void removeAction(int $index)

Removes an Action object from the list of action buttons of this step.

Parameters

int $index The index of the Action object in the list of action buttons

Return Value

void

at line 475
Action|null getActionByName(string $name)

Retrieves an Action object by its name in the list of action buttons of this step

Parameters

string $name The name of the action button

Return Value

Action|null The Action object

at line 491
Footnotes getFootNotes()

Returns the footnotes container of this step

Return Value

Footnotes The footnotes container

at line 503
void setFootNotes(FootNotes $footnotes)

Sets the footnotes container of this step

Parameters

FootNotes $footnotes The footnotes container

Return Value

void

at line 514
bool isDisplayable()

Returns the displayable attribute of this Step object

Return Value

bool true if this step can be displayed, false otherwise

at line 525
bool getDisplayable()

Returns the displayable attribute of this Step object

Return Value

bool true if this step can be displayed, false otherwise

at line 537
void setDisplayable(bool $displayable)

Determines whether this step can be displayed or not

Parameters

bool $displayable true if this step can be displayed, false otherwise

Return Value

void