public class UserAgentService extends Object
| Modifier and Type | Field and Description |
|---|---|
static int |
BUNDLED_BROWSCAP_VERSION |
| Constructor and Description |
|---|
UserAgentService() |
UserAgentService(InputStream zipFileStream)
Creates a user agent service based on the Browscap CSV file in the given ZIP InputStream
|
UserAgentService(String zipFilePath)
Creates a user agent service based on the Browscap CSV file in the given ZIP file
|
| Modifier and Type | Method and Description |
|---|---|
static String |
getBundledCsvFileName()
Returns the bundled ZIP file name
|
UserAgentParser |
loadParser()
Returns a parser based on the bundled BrowsCap version
|
UserAgentParser |
loadParser(Collection<BrowsCapField> fields)
Returns a parser based on the bundled BrowsCap version
|
public static final int BUNDLED_BROWSCAP_VERSION
public UserAgentService()
public UserAgentService(String zipFilePath)
zipFilePath - the zip file should contain the csv file. It will load the given zip file instead of the
bundled onepublic UserAgentService(InputStream zipFileStream)
zipFileStream - the zip InputStream should contain the csv file. It will load the given zip InputStream
instead of the bundled zip filepublic UserAgentParser loadParser() throws IOException, ParseException
IOExceptionParseExceptionpublic UserAgentParser loadParser(Collection<BrowsCapField> fields) throws IOException, ParseException
fields - listIOExceptionParseExceptionpublic static String getBundledCsvFileName()
Copyright © 2023. All rights reserved.