Add mobile device detection to Java the easy way with 51Degrees.com. No cloud services, no external plug-ins, all Mozilla Public Licence source code. It's a great alternative to WURFL or DeviceAtlas.
Also available on Maven.
1) Download the zip and extract.
2) Add the core JAR located in the "dist" directory to your java project.
3) Import the following packages:
4) Use the following code to start detecting devices:
// Uses inbuilt lite data.
p = new Provider();
// An external data file can also be used.
// p = new Provider(StreamFactory.create("PATH_TO_DATA"));
Match match = p.match("USERAGENT_STRING");
boolean isMobile = match.getValues("IsMobile").toBool();
Quick and easy to use!
no trouble to install and run, works nicely.
fiftyone-java is fast and stable