public function type($type) {
        if (!array_key_exists($type, $this->orderedcollection)) {
            $this->orderedcollection[$type] = array();
        }
        return $this->orderedcollection[$type];
    }
public function type($type) {
        if (!array_key_exists($type, $this->orderedcollection)) {
            $this->orderedcollection[$type] = array();
        }
        return $this->orderedcollection[$type];
    }
public function type ( $ type ) { if ( ! array_key_exists ( $ type , $ this -> orderedcollection ) ) { $ this -> orderedcollection [ $ type ] = array ( ) ; } return $ this -> orderedcollection [ $ type ] ; }
Fetches all nodes of a given type from this collection

@param string|int $type  node type being searched for.
@return array ordered collection
Fetches all nodes of a given type from this collection