Package ua_parser

Class Parser

  • Direct Known Subclasses:
    CachingParser

    public class Parser
    extends Object
    Java implementation of UA Parser
    Author:
    Steve Jiang (@sjiang) <gh at iamsteve com>
    • Constructor Detail

      • Parser

        public Parser()
               throws IOException
        Creates a parser using the regular expression yaml file bundled in the jar.
        Throws:
        IOException - if there's a problem reading the file from the classpath
      • Parser

        public Parser​(InputStream regexYaml)
        Creates a parser using the supplied regular expression yaml file. It is the responsibility of the caller to close the InputStream after construction.
        Parameters:
        regexYaml - the yaml file containing the regular expressions