Esempio n. 1
0
    def _checkIntNumber(self, key, s):

        if not Basic.isNumber(s):
            self._error(key, 'Key is not a number')
        if not Basic.isInt(s):
            self._error(key, 'Key is not integer number')

        return int(s)
Esempio n. 2
0
    def _checkFloatNumber(self, key, s):

        if not Basic.isNumber(s):
            self._error(key, 'Key is not a number')
        return float(s)