SectionStorageTrait deprecated
trait SectionStorageTrait (View source)
deprecated
Provides a trait for storing sections on an object.
Traits
Provides a trait for maintaining a list of sections.
Methods
Indicates if this section list contains a blank section.
Indicates if there is a section at the specified delta.
Details
abstract protected $this
setSections(array $sections)
Stores the information for all sections.
Implementations of this method are expected to call array_values() to rekey the list of sections.
count()
{@inheritdoc}
getSection($delta)
{@inheritdoc}
protected $this
setSection(int $delta, Section $section)
Sets the section for the given delta on the display.
appendSection(Section $section)
{@inheritdoc}
insertSection($delta, Section $section)
{@inheritdoc}
protected $this
addBlankSection()
Adds a blank section to the list.
protected bool
hasBlankSection()
Indicates if this section list contains a blank section.
A blank section is used to differentiate the difference between a layout that has never been instantiated and one that has purposefully had all sections removed.
removeSection($delta)
{@inheritdoc}
removeAllSections($set_blank = FALSE)
{@inheritdoc}
protected bool
hasSection(int $delta)
Indicates if there is a section at the specified delta.
__clone()
Magic method: Implements a deep clone.