Sabberworm\CSS\CSSList\Document
The root CSSList of a parsed file. Contains all top-level css contents, mostly declaration blocks, but also any @-rules encountered.
Synopsis
class Document
extends CSSBlockList
{
- // Inherited members from CSSList
- protected $aComments;
- protected $aContents;
- protected $iLineNo;
- // methods
- public void __construct()
- public void getAllDeclarationBlocks()
- public void getAllSelectors()
- public void getAllRuleSets()
- public void getAllValues()
- public void getSelectorsBySpecificity()
- public void expandShorthands()
- public void createShorthands()
- public void render()
- public void isRootList()
- // Inherited methods from CSSBlockList
- public void __construct()
- protected void allDeclarationBlocks()
- protected void allRuleSets()
- protected void allValues()
- protected void allSelectors()
- // Inherited methods from CSSList
- public void __construct()
- public int getLineNo()
- public void append()
- public void remove()
- public void setContents()
- public void removeDeclarationBlockBySelector()
- public void __toString()
- public void render()
- public abstract void isRootList()
- public void getContents()
- public void addComments()
- public array getComments()
- public void setComments()
Hierarchy
Members
protected
- $aComments
- $aContents
- $iLineNo
Methods
public
- __construct() — Document constructor.
- createShorthands() — Create shorthands properties whenever possible
- expandShorthands() — Expands all shorthand properties to their long value
- getAllDeclarationBlocks() — Gets all DeclarationBlock objects recursively.
- getAllRuleSets() — Returns all RuleSet objects found recursively in the tree.
- getAllSelectors()
- getAllValues() — Returns all Value objects found recursively in the tree.
- getSelectorsBySpecificity() — Returns all Selector objects found recursively in the tree.
- isRootList()
- render()
Inherited from Sabberworm\CSS\CSSList\CSSBlockList
protected
Inherited from Sabberworm\CSS\CSSList\CSSList
public
- __toString()
- addComments()
- append()
- getComments()
- getContents()
- getLineNo()
- isRootList() — Return true if the list can not be further outdented. Only important when rendering.
- remove() — Removes an item from the CSS list.
- removeDeclarationBlockBySelector() — Removes a declaration block from the CSS list if it matches all given selectors.
- render()
- setComments()
- setContents() — Set the contents.