Class ParserUtil


  • public class ParserUtil
    extends java.lang.Object
    • Constructor Summary

      Constructors 
      Constructor Description
      ParserUtil()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      private void fillList​(java.util.List<java.util.List<java.lang.Integer>> codePoints, java.lang.String value)  
      java.util.List<java.util.List<java.lang.Integer>> parseToListArrayInt​(java.lang.String file)
      Parse a file with ranges of hexadecimal to a list of list of integers.
      java.util.List<java.util.List<java.lang.Integer>> parseToListArrayInt​(java.lang.String file, java.util.regex.Pattern pattern)
      Parse a file with ranges of hexadecimal to a list of list of integers.
      java.util.List<java.lang.Integer> parseToListInteger​(java.lang.String file, java.util.regex.Pattern pattern)
      Parse a file with hexadecimal to a list of integers.
      java.util.Map<java.lang.Integer,​java.util.List<java.lang.Integer>> parseToMapListInteger​(java.lang.String file, java.util.regex.Pattern patternLine, java.util.regex.Pattern mapTo)
      Parse a file with mappings to a map of list of integers.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ParserUtil

        public ParserUtil()
    • Method Detail

      • parseToListInteger

        public java.util.List<java.lang.Integer> parseToListInteger​(java.lang.String file,
                                                                    java.util.regex.Pattern pattern)
                                                             throws java.lang.NumberFormatException,
                                                                    java.io.IOException
        Parse a file with hexadecimal to a list of integers.
        Parameters:
        file - with the RFC file to parse
        pattern - of the lines
        Returns:
        list of integers
        Throws:
        java.io.IOException - if a RFC file can't be read
        java.lang.NumberFormatException
      • parseToMapListInteger

        public java.util.Map<java.lang.Integer,​java.util.List<java.lang.Integer>> parseToMapListInteger​(java.lang.String file,
                                                                                                              java.util.regex.Pattern patternLine,
                                                                                                              java.util.regex.Pattern mapTo)
                                                                                                       throws java.io.IOException
        Parse a file with mappings to a map of list of integers.
        Parameters:
        file - with THE RFC file to parse
        patternLine - pattern of the lines
        mapTo - pattern of the conversion
        Returns:
        map of list of integers
        Throws:
        java.io.IOException - if a RFC file can't be read
      • parseToListArrayInt

        public java.util.List<java.util.List<java.lang.Integer>> parseToListArrayInt​(java.lang.String file)
                                                                              throws java.lang.NumberFormatException,
                                                                                     java.io.IOException
        Parse a file with ranges of hexadecimal to a list of list of integers.
        Parameters:
        file - with the RFC file to parse
        Returns:
        list of list of integers
        Throws:
        java.io.IOException - if a RFC file can't be read
        java.lang.NumberFormatException
      • parseToListArrayInt

        public java.util.List<java.util.List<java.lang.Integer>> parseToListArrayInt​(java.lang.String file,
                                                                                     java.util.regex.Pattern pattern)
                                                                              throws java.lang.NumberFormatException,
                                                                                     java.io.IOException
        Parse a file with ranges of hexadecimal to a list of list of integers.
        Parameters:
        file - with the RFC file to parse
        pattern - of the lines
        Returns:
        list of list of integers
        Throws:
        java.io.IOException - if a RFC file can't be read
        java.lang.NumberFormatException
      • fillList

        private void fillList​(java.util.List<java.util.List<java.lang.Integer>> codePoints,
                              java.lang.String value)