mirror of
https://gitee.com/chinabugotech/hutool.git
synced 2025-07-21 15:09:48 +08:00
add SetUtil
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
package cn.hutool.http.server.action;
|
||||
|
||||
import cn.hutool.core.collection.CollUtil;
|
||||
import cn.hutool.core.collection.ListUtil;
|
||||
import cn.hutool.core.io.FileUtil;
|
||||
import cn.hutool.http.server.HttpServerRequest;
|
||||
import cn.hutool.http.server.HttpServerResponse;
|
||||
@@ -58,7 +58,7 @@ public class RootAction implements Action {
|
||||
*/
|
||||
public RootAction(final File rootDir, final String... indexFileNames) {
|
||||
this.rootDir = rootDir;
|
||||
this.indexFileNames = CollUtil.toList(indexFileNames);
|
||||
this.indexFileNames = ListUtil.toList(indexFileNames);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@@ -1,6 +1,6 @@
|
||||
package cn.hutool.http.useragent;
|
||||
|
||||
import cn.hutool.core.collection.CollUtil;
|
||||
import cn.hutool.core.collection.ListUtil;
|
||||
import cn.hutool.core.regex.ReUtil;
|
||||
|
||||
import java.util.List;
|
||||
@@ -27,7 +27,7 @@ public class Browser extends UserAgentInfo {
|
||||
/**
|
||||
* 支持的浏览器类型
|
||||
*/
|
||||
public static final List<Browser> browers = CollUtil.newArrayList(
|
||||
public static final List<Browser> browers = ListUtil.toList(
|
||||
// 部分特殊浏览器是基于安卓、Iphone等的,需要优先判断
|
||||
// 企业微信 企业微信使用微信浏览器内核,会包含 MicroMessenger 所以要放在前面
|
||||
new Browser("wxwork", "wxwork", "wxwork\\/([\\d\\w\\.\\-]+)"),
|
||||
|
@@ -1,6 +1,6 @@
|
||||
package cn.hutool.http.useragent;
|
||||
|
||||
import cn.hutool.core.collection.CollUtil;
|
||||
import cn.hutool.core.collection.ListUtil;
|
||||
import cn.hutool.core.regex.ReUtil;
|
||||
|
||||
import java.util.List;
|
||||
@@ -21,7 +21,7 @@ public class Engine extends UserAgentInfo {
|
||||
/**
|
||||
* 支持的引擎类型
|
||||
*/
|
||||
public static final List<Engine> engines = CollUtil.newArrayList(
|
||||
public static final List<Engine> engines = ListUtil.of(
|
||||
new Engine("Trident", "trident"),
|
||||
new Engine("Webkit", "webkit"),
|
||||
new Engine("Chrome", "chrome"),
|
||||
|
@@ -1,6 +1,6 @@
|
||||
package cn.hutool.http.useragent;
|
||||
|
||||
import cn.hutool.core.collection.CollUtil;
|
||||
import cn.hutool.core.collection.ListUtil;
|
||||
import cn.hutool.core.regex.ReUtil;
|
||||
|
||||
import java.util.List;
|
||||
@@ -23,7 +23,7 @@ public class OS extends UserAgentInfo {
|
||||
/**
|
||||
* 支持的引擎类型
|
||||
*/
|
||||
public static final List<OS> oses = CollUtil.newArrayList(//
|
||||
public static final List<OS> oses = ListUtil.of(//
|
||||
new OS("Windows 10 or Windows Server 2016", "windows nt 10\\.0", "windows nt (10\\.0)"),//
|
||||
new OS("Windows 8.1 or Windows Server 2012R2", "windows nt 6\\.3", "windows nt (6\\.3)"),//
|
||||
new OS("Windows 8 or Windows Server 2012", "windows nt 6\\.2", "windows nt (6\\.2)"),//
|
||||
|
@@ -1,6 +1,6 @@
|
||||
package cn.hutool.http.useragent;
|
||||
|
||||
import cn.hutool.core.collection.CollUtil;
|
||||
import cn.hutool.core.collection.ListUtil;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
@@ -49,7 +49,7 @@ public class Platform extends UserAgentInfo {
|
||||
/**
|
||||
* 支持的移动平台类型
|
||||
*/
|
||||
public static final List<Platform> mobilePlatforms = CollUtil.newArrayList(//
|
||||
public static final List<Platform> mobilePlatforms = ListUtil.of(//
|
||||
WINDOWS_PHONE, //
|
||||
IPAD, //
|
||||
IPOD, //
|
||||
@@ -65,7 +65,7 @@ public class Platform extends UserAgentInfo {
|
||||
/**
|
||||
* 支持的桌面平台类型
|
||||
*/
|
||||
public static final List<Platform> desktopPlatforms = CollUtil.newArrayList(//
|
||||
public static final List<Platform> desktopPlatforms = ListUtil.of(//
|
||||
new Platform("Windows", "windows"), //
|
||||
new Platform("Mac", "(macintosh|darwin)"), //
|
||||
new Platform("Linux", "linux"), //
|
||||
|
Reference in New Issue
Block a user