Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.75 Safari/537.36
Mac
Firefox
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:65.0) Gecko/20100101 Firefox/65.0
Mac
Safari
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/12.0.3 Safari/605.1.15
Windows
Chrome
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/72.0.3626.121 Safari/537.36
Windows
Edge
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.140 Safari/537.36 Edge/18.17763
Windows
IE
Mozilla/5.0 (Windows NT 10.0; WOW64; Trident/7.0; rv:11.0) like Gecko
iOS
Safari
Mozilla/5.0 (iPhone; CPU iPhone OS 17_5_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/17.5 Mobile/15E148 Safari/604.1
iOS
Chrome
Mozilla/5.0 (iPhone; CPU iPhone OS 17_5 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) CriOS/126.0.6478.108 Mobile/15E148 Safari/604.1
iOS
UC浏览器
Mozilla/5.0 (iPhone; CPU iPhone OS 17_5_1 like Mac OS X; zh-CN) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/21F90 UCBrowser/16.5.9.2353 Mobile AliApp(TUnionSDK/0.1.20.4)
iOS
跨克浏览器
Mozilla/5.0 (iPhone; CPU iPhone OS 17_5_1 like Mac OS X; zh-cn) AppleWebKit/601.1.46 (KHTML, like Gecko) Mobile/21F90 Quark/7.0.1.2158 Mobile
Android
Chrome
Mozilla/5.0 (Linux; Android 4.2.1; M040 Build/JOP40D) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/31.0.1650.59 Mobile Safari/537.36
Android
Webkit
Mozilla/5.0 (Linux; U; Android 4.4.4; zh-cn; M351 Build/KTU84P) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Mobile Safari/534.30
Mobile APP userAgent 大全
系统
APP
User-Agent字符串
iOS
CSDN
Mozilla/5.0 (iPhone; CPU iPhone OS 17_5_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/15E148 CSDNApp/6.3.8(iOS)
iOS
知乎
Mozilla/5.0 (iPhone; CPU iPhone OS 17_5_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/15E148 osee2unifiedRelease/19106 osee2unifiedReleaseVersion/10.11.0 ZhihuHybrid
iOS
钉钉
Mozilla/5.0 (iPhone; CPU iPhone OS 17_5_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/21F90 AliApp(DingTalk/7.5.35) com.laiwang.DingTalk/37648190 Channel/201200 language/zh-Hans-CN UT4Aplus/0.0.6 WK
iOS
QQ
Mozilla/5.0 (iPhone; CPU iPhone OS 17_5_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/15E148 QQ/9.0.65.617 V1_IPH_SQ_9.0.65_1_APP_A Pixel/828 MiniAppEnable SimpleUISwitch/0 StudyMode/0 CurrentMode/0 CurrentFontScale/1.000000 QQTheme/2105 AppId/537224259 Core/WKWebView Device/Apple(iPhone 11) NetType/WIFI QBWebViewType/1 WKType/1
iOS
微信
Mozilla/5.0 (iPhone; CPU iPhone OS 17_5_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/15E148 MicroMessenger/8.0.49(0x18003137) NetType/WIFI Language/zh_CN
iOS
支付宝
Mozilla/5.0 (iPhone; CPU iPhone OS 17_5_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/21F90 ChannelId(14) Ariver/1.1.0 AliApp(AP/10.6.6.6000) Nebula WK RVKType(1) AlipayDefined(nt:WIFI,ws:414
iOS
掘金
Mozilla/5.0 (iPhone; CPU iPhone OS 17_5_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/15E148/JueJinAPP
iOS
Safari
Mozilla/5.0 (iPhone; CPU iPhone OS 17_5_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/17.5 Mobile/15E148 Safari/604.1
iOS
Chrome
Mozilla/5.0 (iPhone; CPU iPhone OS 17_5 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) CriOS/126.0.6478.108 Mobile/15E148 Safari/604.1
iOS
UC浏览器
Mozilla/5.0 (iPhone; CPU iPhone OS 17_5_1 like Mac OS X; zh-CN) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/21F90 UCBrowser/16.5.9.2353 Mobile AliApp(TUnionSDK/0.1.20.4)
iOS
跨克浏览器
Mozilla/5.0 (iPhone; CPU iPhone OS 17_5_1 like Mac OS X; zh-cn) AppleWebKit/601.1.46 (KHTML, like Gecko) Mobile/21F90 Quark/7.0.1.2158 Mobile
JS 判断当前 APP
functionextractAppName(userAgentString){var appName ="Unknown";if(userAgentString.includes("CSDNApp")){appName ="CSDN";}elseif(userAgentString.includes("osee2unifiedRelease")){appName ="知乎";}elseif(userAgentString.includes("AliApp(DingTalk")){appName ="钉钉";}elseif(userAgentString.includes("QQ/")){appName ="QQ";}elseif(userAgentString.includes("MicroMessenger/")){appName ="微信";}elseif(userAgentString.includes("AliApp(AP/")){appName ="支付宝";}elseif(userAgentString.includes("JueJinAPP")){appName ="掘金";}elseif(userAgentString.includes("Safari/")&&!userAgentString.includes("CriOS")){appName ="Safari";}elseif(userAgentString.includes("CriOS/")){appName ="Chrome";}elseif(userAgentString.includes("UCBrowser/")){appName ="UC浏览器";}elseif(userAgentString.includes("Quark/")){appName ="跨克浏览器";}return appName;}console.log(extractAppName("Mozilla/5.0 (iPhone; CPU iPhone OS 17_5_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/15E148 CSDNApp/6.3.8(iOS)"));
对于一个基本的类
public class BaseDao<T>{T findOne() {return T;}
}它的子类
public class StudentDao extends BaseDao<StudentDao.Student>{public static class Student{}}如何获得当前类对应的泛型参数呢?
方法一 JDK
public static void ma…
力扣2874.有序三元组中的最大值 II 遍历j –> 找j左边最大数 和右边最大数 class Solution {public:long long maximumTripletValue(vector<int>& nums) {int n nums.size();vector<int> suf_max(n1,0);//右边最大数for(int in-1;i>1;i--){suf_max[i…