public static function getNodeName($nodeString)
    {
        $positionOfFirstAttribute = strpos($nodeString, '[@');

        if ($positionOfFirstAttribute === false) {
            return $nodeString;
        }

        return substr($nodeString, 0, $positionOfFirstAttribute);
    }