Delete UaAnalyserTest.java
This commit is contained in:
@@ -1,34 +0,0 @@
|
||||
import com.example.ua.analyser.UaAnalyser;
|
||||
import com.example.ua.analyser.enums.UserInfo;
|
||||
import com.example.ua.analyser.impl.UaAnalyserImpl;
|
||||
import com.example.ua.config.ApplicationConfig;
|
||||
|
||||
import java.awt.*;
|
||||
import java.lang.reflect.Field;
|
||||
|
||||
public class UaAnalyserTest {
|
||||
|
||||
|
||||
public static void main(String[] args){
|
||||
|
||||
String inputString = "69765" + "\t" + // userId
|
||||
"192.168.50.13" + "\t" + // ip
|
||||
"1765433230" + "\t" + // timeStamp
|
||||
"'Dalvik/1.6.0 (Linux; U; Android 4.0.3; LG-E612f Build/IML74K)':4, " +
|
||||
"'Dalvik/2.1.0 (Linux; U; Android 10; TNYAL00 Build/HUAWEITNY-AL00)':4" +
|
||||
"'Mozilla/5.0 (iPhone; CPU iPhone OS 11_4_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/15G77 === iOS/11.4.1 Model/iPhone10,1 BundleID/com.xunmeng.pinduoduo AppVersion/5.32.0 AppBuild/2009212125 pversion/1221 cURL/7.48.0':5" +
|
||||
"'com.apple.trustd/1.0':1" +
|
||||
"'server-bag [iPhone OS,13.6.1,17G80,iPhone10,2]':1" +
|
||||
"'Microsoft-CryptoAPI/10.0':1" +
|
||||
"'Mozilla/5.0 (Linux; Android 10; SM-G9600) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/86.0.4240.110 Mobile Safari/537.36':10" +
|
||||
"'Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/67.0.3396.99 Safari/537.36':1"; // uaCntInfo
|
||||
|
||||
UaAnalyser uaAnalyser = new UaAnalyserImpl();
|
||||
UserInfo userInfo = uaAnalyser.getUserinfo(inputString);
|
||||
|
||||
// 获取相关字段:
|
||||
// osCnt, browserCnt, deviceCnt, terminalCnt, terminalCatCnt,
|
||||
// osList, browserList, deviceList, terminalList, terminalCatList
|
||||
System.out.println(userInfo.getTerminalList()); // 获取terminalList字段值
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user