New customers can spin up VMs, build with AI, and query data at no cost.
Put your $300 in credit toward real workloads, then keep building with free monthly usage for 20+ products. No commitment and no charge until you upgrade.
Start Free
Go from Code to Production URL in Seconds
Cloud Run deploys apps in any language instantly. Scales to zero. Pay only when code runs.
Skip the Kubernetes configs. Cloud Run handles HTTPS, scaling, and infrastructure automatically. Two million requests free per month.
Mobile Device Detection for Java - 4 Step Setup - 3 minutes
...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:
import fiftyone.mobile.detection.Match;
import fiftyone.mobile.detection.Provider;
import fiftyone.mobile.detection.factories.StreamFactory;
4) Use the following code to start detecting devices:
//The Lite data file is provided with every archive.
Provider p = new Provider(StreamFactory.create("path/to/data/file"));
Match match = p.match("USERAGENT_STRING");
boolean isMobile = match.getValues("IsMobile").toBool();
if(isMobile)
System.out.println("Mobile");
else
System.out.println("Not mobile");