AccordionItemNode
extends GeneralDirectiveNode
in package
implements
LinkTargetNode, OptionalLinkTargetsNode, PrefixedLinkTargetNode
FinalYes
A catch-all directive Node containing all information about the original directive in rst.
Table of Contents
Interfaces
- LinkTargetNode
- OptionalLinkTargetsNode
- Makes the implementing node an optional link target. If Noindex is true no references are generated, there is no entry in the objects index and no warning about duplicate ids.
- PrefixedLinkTargetNode
Constants
- LINK_PREFIX = 'accordion-'
- LINK_TYPE = 'std:accordion'
Properties
- $classes : array<string|int, string>
- $content : InlineCompoundNode
- $name : string
- $options : array<string, scalar|null>
- $plainContent : string
- $title : TitleNode
- $value : TValue
- $id : string
- $show : bool
Methods
- __construct() : mixed
- addChildNode() : void
- getAnchor() : string
- getChildren() : array<string|int, TValue>
- getClasses() : array<string|int, string>
- getClassesString() : string
- getContent() : InlineCompoundNode
- getId() : string
- getLinkText() : string
- getLinkType() : string
- getName() : string
- getOption() : mixed
- getOptions() : array<string, scalar|null>
- getPlainContent() : string
- getPrefix() : string
- getTitle() : TitleNode
- getValue() : TValue
- hasOption() : bool
- isNoindex() : bool
- isShow() : bool
- pushChildNode() : void
- removeNode() : self
- replaceNode() : self
- setClasses() : void
- Normalizes class names following the rules of identifier-normalization
- setValue() : void
- withKeepExistingOptions() : static
- Adds $options as default options without overriding any options already set.
- withOptions() : static
Constants
LINK_PREFIX
public
mixed
LINK_PREFIX
= 'accordion-'
LINK_TYPE
public
mixed
LINK_TYPE
= 'std:accordion'
Properties
$classes
protected
array<string|int, string>
$classes
= []
$content read-only
protected
InlineCompoundNode
$content
$name read-only
protected
string
$name
$options
protected
array<string, scalar|null>
$options
= []
$plainContent read-only
protected
string
$plainContent
$title read-only
protected
TitleNode
$title
$value
protected
TValue
$value
$id read-only
private
string
$id
= ''
$show read-only
private
bool
$show
= false
Methods
__construct()
public
__construct(string $name, string $plainContent, InlineCompoundNode $content, TitleNode $title[, array<int, Node> $value = [] ][, string $id = '' ][, bool $show = false ]) : mixed
Parameters
- $name : string
- $plainContent : string
- $content : InlineCompoundNode
- $title : TitleNode
- $value : array<int, Node> = []
- $id : string = ''
- $show : bool = false
addChildNode()
public
addChildNode(TValue $node) : void
Parameters
- $node : TValue
getAnchor()
public
getAnchor() : string
Return values
stringgetChildren()
public
getChildren() : array<string|int, TValue>
Return values
array<string|int, TValue>getClasses()
public
getClasses() : array<string|int, string>
Return values
array<string|int, string>getClassesString()
public
getClassesString() : string
Return values
stringgetContent()
public
getContent() : InlineCompoundNode
Return values
InlineCompoundNodegetId()
public
getId() : string
Return values
stringgetLinkText()
public
getLinkText() : string
Return values
stringgetLinkType()
public
getLinkType() : string
Return values
stringgetName()
public
getName() : string
Return values
stringgetOption()
public
getOption(string $name[, TType|null $default = null ]) : mixed
Parameters
- $name : string
- $default : TType|null = null
Tags
getOptions()
public
getOptions() : array<string, scalar|null>
Return values
array<string, scalar|null>getPlainContent()
public
getPlainContent() : string
Return values
stringgetPrefix()
public
getPrefix() : string
Return values
stringgetTitle()
public
getTitle() : TitleNode
Return values
TitleNodegetValue()
public
getValue() : TValue
Return values
TValuehasOption()
public
hasOption(string $name) : bool
Parameters
- $name : string
Return values
boolisNoindex()
public
isNoindex() : bool
Return values
boolisShow()
public
isShow() : bool
Return values
boolpushChildNode()
public
pushChildNode(TValue $node) : void
Parameters
- $node : TValue
removeNode()
public
removeNode(int $key) : self
Parameters
- $key : int
Tags
Return values
selfreplaceNode()
public
replaceNode(int $key, TValue $node) : self
Parameters
- $key : int
- $node : TValue
Tags
Return values
selfsetClasses()
Normalizes class names following the rules of identifier-normalization
public
setClasses(array<string|int, string> $classes) : void
Parameters
- $classes : array<string|int, string>
Tags
setValue()
public
setValue(TValue $value) : void
Parameters
- $value : TValue
withKeepExistingOptions()
Adds $options as default options without overriding any options already set.
public
withKeepExistingOptions(array<string, scalar|null> $options) : static
Parameters
- $options : array<string, scalar|null>
Return values
staticwithOptions()
public
withOptions(array<string, scalar|null> $options) : static
Parameters
- $options : array<string, scalar|null>