osu-wayback/helpers/validatorHelper.py

13 lines
224 B
Python
Raw Normal View History

2019-03-11 14:41:55 +01:00
import string
def HEX(data):
return len( [x for x in data if x in string.hexdigits] ) == len(data)
def INT(data):
return str.isnumeric(data)
def DEC(data):
return str.isdecimal(data)
def STR(data):
return str.isalpha