MatchesXsByte🔗
Check that
text conforms to the pattern of an xs:byte.
Code
byte_rep = r"[\-+]?0*[0-9]{1,3}"
pattern = f"^{byte_rep}$"
return match(pattern, text) is not None