Extracted hex and decimal parsing logic into separate methods to
address SonarQube complexity warning:
- parseHexEntity(): handles ઼ format
- parseDecimalEntity(): handles { format
This reduces cyclomatic complexity while maintaining identical
functionality and all validation checks.