public function getVersion(\DOMDocument $document)
    {
        if (empty($document->documentElement)) {
            return '';
        }

        $xpath = $this->getXpath($document);
        $this->setNs($document);
        $xpath->registerNamespace('cbc', self::CBC_NS);

        return $this->getSingleValue($xpath, 'cbc:UBLVersionID');
    }
public function getVersion(\DOMDocument $document)
    {
        if (empty($document->documentElement)) {
            return '';
        }

        $xpath = $this->getXpath($document);
        $this->setNs($document);
        $xpath->registerNamespace('cbc', self::CBC_NS);

        return $this->getSingleValue($xpath, 'cbc:UBLVersionID');
    }
public function getVersion ( \ DOMDocument $ document ) { if ( empty ( $ document -> documentElement ) ) { return '' ; } $ xpath = $ this -> getXpath ( $ document ) ; $ this -> setNs ( $ document ) ; $ xpath -> registerNamespace ( 'cbc' , self :: CBC_NS ) ; return $ this -> getSingleValue ( $ xpath , 'cbc:UBLVersionID' ) ; }
UBL Version resolver.

@param \DOMDocument $document
@return string
UBL Version resolver .