Chapter
class Chapter
This class allows the storage and retrieval of the attributes of a chapter
Properties
private BlockInfo | $blocinfo | ||
private int | $id | ||
private string | $name | ||
private string | $label | ||
private string | $icon | ||
private bool | $collapsible | ||
private array | $sections | ||
private bool | $displayable |
Methods
Retrieves the BlockInfo object that contains this chapter
Retrieves the ID of this chapter
Sets the ID of this chapter
Retrieves the name of this chapter
Sets the name of this chapter
Retrieves the label of this chapter
Sets the label of this chapter
Retrieves the icon of this chapter
Sets the icon of this chapter
Retrieves the collapsible attribute of this Chapter object
Retrieves the collapsible attribute of this Chapter object
Determines whether this Chapter can be collapsed /expanded or not
Returns the list of sections contained in this Chapter object
Sets the list of sections contained in this Chapter object
Adds a section to the list of sections contained in this Chapter object
Removes a section from the list of sections contained in this Chapter object
Retrieves a section by its ID in the sections list of this Chapter object
Returns the displayable attribute of this Chapter object
Determines whether this Chapter can be displayed or not
Details
at line 112
void
__construct(BlockInfo $blocinfo, int $id)
Constructor of class Chapter
at line 124
BlockInfo
getBlocinfo()
Retrieves the BlockInfo object that contains this chapter
at line 135
int
getId()
Retrieves the ID of this chapter
at line 147
void
setId(int $id)
Sets the ID of this chapter
at line 158
string
getName()
Retrieves the name of this chapter
at line 170
void
setName(string $name)
Sets the name of this chapter
at line 181
string
getLabel()
Retrieves the label of this chapter
at line 193
void
setLabel(string $label)
Sets the label of this chapter
at line 204
string
getIcon()
Retrieves the icon of this chapter
at line 216
void
setIcon(string $icon)
Sets the icon of this chapter
at line 227
bool
isCollapsible()
Retrieves the collapsible attribute of this Chapter object
at line 238
bool
getCollapsible()
Retrieves the collapsible attribute of this Chapter object
at line 250
void
setCollapsible(bool $collapsible)
Determines whether this Chapter can be collapsed /expanded or not
at line 261
array
getSections()
Returns the list of sections contained in this Chapter object
at line 273
void
setSections(array $sections)
Sets the list of sections contained in this Chapter object
at line 285
void
addSection(Section $section)
Adds a section to the list of sections contained in this Chapter object
at line 297
void
removeSection(int $index)
Removes a section from the list of sections contained in this Chapter object
at line 309
Section|null
getSectionById(int $id)
Retrieves a section by its ID in the sections list of this Chapter object
at line 325
bool
isDisplayable()
Returns the displayable attribute of this Chapter object
at line 337
void
setDisplayable(bool $displayable)
Determines whether this Chapter can be displayed or not