Automattic\WooCommerce\Vendor\Sabberworm\CSS\CSSList

CSSBlockList::allDeclarationBlocksprotectedWC 1.0

Method of the class: CSSBlockList{}

No Hooks.

Returns

null. Nothing (null).

Usage

// protected - for code of main (parent) or child class
$result = $this->allDeclarationBlocks( $aResult );
$aResult(array) (required)
.

CSSBlockList::allDeclarationBlocks() code WC 10.5.0

protected function allDeclarationBlocks(array &$aResult)
{
    foreach ($this->aContents as $mContent) {
        if ($mContent instanceof DeclarationBlock) {
            $aResult[] = $mContent;
        } elseif ($mContent instanceof CSSBlockList) {
            $mContent->allDeclarationBlocks($aResult);
        }
    }
}