Jackalope\NodeType\NodeTypeManager::getDeclaredSubtypes PHP Method

getDeclaredSubtypes() public method

Helper method for node types: Returns the declared subtypes of a given nodename.
See also: NodeType::getDeclaredSubtypes
public getDeclaredSubtypes ( string $nodeTypeName ) : array
$nodeTypeName string
return array with the names of the subnode types pointing to the node type instances
    public function getDeclaredSubtypes($nodeTypeName)
    {
        // OPTIMIZE: any way to avoid loading all nodes at this point?
        $this->fetchNodeTypes();
        if (empty($this->nodeTree[$nodeTypeName])) {
            return array();
        }
        return $this->nodeTree[$nodeTypeName];
    }