Class Report
Baseclass for reports.
This class follows the pattern with inheritance from Lua classes.
Metamethods
Report:__index (key) | Lookup of missing class members. |
Methods
Report:create (...) | Create a new instance. |
Report:_init (...) | Initialize a new instance. |
Report:notOk () | Set the state unconditionally as "not ok"". |
Report:ok () | Set the state unconditionally as "ok"". |
Report:isOk () | Check if the instance state is "ok"". |
Report:setSkip ([arg='']) | Set the skip. |
Report:getSkip () | Get the skip. |
Report:isSkip () | Check if the instance is itself in a skip state. |
Report:setTodo ([arg='']) | Set the todo. |
Report:getTodo () | Get the todo. |
Report:isTodo () | Check if the instance is itself in a todo state. |
Report:realize (renders, lang, counter) | Realize the data by applying a render. |
Report:type () | Get the type of report. |
Metamethods
- Report:__index (key)
-
Lookup of missing class members.
Parameters:
- key string lookup of member
Returns:
anyRaises:
on wrong arguments
Methods
- Report:create (...)
-
Create a new instance.
Assumption is either to create a new instance from an existing class,
or from a previous instance of some kind.
Parameters:
- ...
vararg
forwarded to
_init()
Returns:
self - ...
vararg
forwarded to
- Report:_init (...)
-
Initialize a new instance.
Parameters:
- ... vararg unused
Returns:
self - Report:notOk ()
-
Set the state unconditionally as "not ok"".
Note that initial state is not ok.
Returns:
self - Report:ok ()
-
Set the state unconditionally as "ok"".
Note that initial state is not ok.
Returns:
self - Report:isOk ()
-
Check if the instance state is "ok"".
Note that initial state is not ok.
Returns:
boolean the existing state - Report:setSkip ([arg=''])
-
Set the skip.
This is an accessor to set the member.
Parameters:
Returns:
selfRaises:
on wrong arguments - Report:getSkip ()
-
Get the skip.
This is an accessor to get the member.
Note that the saved structure will be unpacked before being returned.
Returns:
string the skip note - Report:isSkip ()
-
Check if the instance is itself in a skip state.
Returns:
boolean does the skip note exist - Report:setTodo ([arg=''])
-
Set the todo.
This is an accessor to set the member.
Parameters:
Returns:
selfRaises:
on wrong arguments - Report:getTodo ()
-
Get the todo.
This is an accessor to get the member.
Returns:
string the todo note - Report:isTodo ()
-
Check if the instance is itself in a todo state.
Returns:
boolean does the todo note exist - Report:realize (renders, lang, counter)
-
Realize the data by applying a render.
Parameters:
- renders Renders to use while realizing the Baseclasss (unused)
- lang nil or string holding the language code (unused)
- counter nil or Counter holding the running count (unused)
Returns:
string - Report:type ()
-
Get the type of report.
All reports has an explicit type name.
Returns:
string