(self, elem, extname, default=None)
return default
Determine the extension revision from the EXTENSION_NAME_SPEC_VERSION
        enumerant.

        - elem - <extension> element to query
        - extname - extension name from the <extension> 'name' attribute
        - default - default value if SPEC_VERSION token not present
Determine the extension revision from the EXTENSION_NAME_SPEC_VERSION
        enumerant.
Determine the extension revision from the EXTENSION_NAME_SPEC_VERSION enumerant .
def getSpecVersion(self, elem, extname, default=None):
        """Determine the extension revision from the EXTENSION_NAME_SPEC_VERSION
        enumerant.

        - elem - <extension> element to query
        - extname - extension name from the <extension> 'name' attribute
        - default - default value if SPEC_VERSION token not present"""
        # The literal enumerant name to match
        versioningEnumName = self.numbersToWords(extname.upper()) + '_SPEC_VERSION'

        for enum in elem.findall('./require/enum'):
            enumName = self.getAttrib(enum, 'name')
            if enumName == versioningEnumName:
                return self.getAttrib(enum, 'value')

        #if not found:
        for enum in elem.findall('./require/enum'):
            enumName = self.getAttrib(enum, 'name')
            if enumName.find('SPEC_VERSION') != -1:
                self.logMsg('diag', 'Missing ' + versioningEnumName + '! Potential misnamed candidate ' + enumName + '.')
                return self.getAttrib(enum, 'value')

        self.logMsg('error', 'Missing ' + versioningEnumName + '!')
        return default
def getSpecVersion ( self , elem , extname , default = None ) : # The literal enumerant name to match versioningEnumName = self . numbersToWords ( extname . upper ( ) ) + '_SPEC_VERSION' for enum in elem . findall ( './require/enum' ) : enumName = self . getAttrib ( enum , 'name' ) if enumName == versioningEnumName : return self . getAttrib ( enum , 'value' ) #if not found: for enum in elem . findall ( './require/enum' ) : enumName = self . getAttrib ( enum , 'name' ) if enumName . find ( 'SPEC_VERSION' ) != - 1 : self . logMsg ( 'diag' , 'Missing ' + versioningEnumName + '! Potential misnamed candidate ' + enumName + '.' ) return self . getAttrib ( enum , 'value' ) self . logMsg ( 'error' , 'Missing ' + versioningEnumName + '!' ) return default