mirror of
https://gitee.com/chinabugotech/hutool.git
synced 2025-05-09 23:51:34 +08:00
fix name
This commit is contained in:
parent
c1a895bce5
commit
5b5209e801
@ -3,7 +3,7 @@ package cn.hutool.http.client.cookie;
|
|||||||
import cn.hutool.core.io.IORuntimeException;
|
import cn.hutool.core.io.IORuntimeException;
|
||||||
import cn.hutool.core.map.MapUtil;
|
import cn.hutool.core.map.MapUtil;
|
||||||
import cn.hutool.core.net.url.URLUtil;
|
import cn.hutool.core.net.url.URLUtil;
|
||||||
import cn.hutool.http.client.engine.jdk.HttpConnection;
|
import cn.hutool.http.client.engine.jdk.JdkHttpConnection;
|
||||||
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.net.CookieManager;
|
import java.net.CookieManager;
|
||||||
@ -63,16 +63,16 @@ public class GlobalCookieManager {
|
|||||||
* @return Cookie信息列表
|
* @return Cookie信息列表
|
||||||
* @since 4.6.9
|
* @since 4.6.9
|
||||||
*/
|
*/
|
||||||
public static List<HttpCookie> getCookies(final HttpConnection conn){
|
public static List<HttpCookie> getCookies(final JdkHttpConnection conn){
|
||||||
return cookieManager.getCookieStore().get(getURI(conn));
|
return cookieManager.getCookieStore().get(getURI(conn));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 将本地存储的Cookie信息附带到Http请求中,不覆盖用户定义好的Cookie
|
* 将本地存储的Cookie信息附带到Http请求中,不覆盖用户定义好的Cookie
|
||||||
*
|
*
|
||||||
* @param conn {@link HttpConnection}
|
* @param conn {@link JdkHttpConnection}
|
||||||
*/
|
*/
|
||||||
public static void add(final HttpConnection conn) {
|
public static void add(final JdkHttpConnection conn) {
|
||||||
if(null == cookieManager) {
|
if(null == cookieManager) {
|
||||||
// 全局Cookie管理器关闭
|
// 全局Cookie管理器关闭
|
||||||
return;
|
return;
|
||||||
@ -93,9 +93,9 @@ public class GlobalCookieManager {
|
|||||||
/**
|
/**
|
||||||
* 存储响应的Cookie信息到本地
|
* 存储响应的Cookie信息到本地
|
||||||
*
|
*
|
||||||
* @param conn {@link HttpConnection}
|
* @param conn {@link JdkHttpConnection}
|
||||||
*/
|
*/
|
||||||
public static void store(final HttpConnection conn) {
|
public static void store(final JdkHttpConnection conn) {
|
||||||
store(conn, conn.headers());
|
store(conn, conn.headers());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -103,10 +103,10 @@ public class GlobalCookieManager {
|
|||||||
* 存储响应的Cookie信息到本地<br>
|
* 存储响应的Cookie信息到本地<br>
|
||||||
* 通过读取
|
* 通过读取
|
||||||
*
|
*
|
||||||
* @param conn {@link HttpConnection}
|
* @param conn {@link JdkHttpConnection}
|
||||||
* @param responseHeaders 头信息Map
|
* @param responseHeaders 头信息Map
|
||||||
*/
|
*/
|
||||||
public static void store(final HttpConnection conn, final Map<String, List<String>> responseHeaders) {
|
public static void store(final JdkHttpConnection conn, final Map<String, List<String>> responseHeaders) {
|
||||||
if(null == cookieManager || MapUtil.isEmpty(responseHeaders)) {
|
if(null == cookieManager || MapUtil.isEmpty(responseHeaders)) {
|
||||||
// 全局Cookie管理器关闭或头信息为空
|
// 全局Cookie管理器关闭或头信息为空
|
||||||
return;
|
return;
|
||||||
@ -124,7 +124,7 @@ public class GlobalCookieManager {
|
|||||||
* @param conn HttpConnection
|
* @param conn HttpConnection
|
||||||
* @return URI
|
* @return URI
|
||||||
*/
|
*/
|
||||||
private static URI getURI(final HttpConnection conn){
|
private static URI getURI(final JdkHttpConnection conn){
|
||||||
return URLUtil.toURI(conn.getUrl());
|
return URLUtil.toURI(conn.getUrl());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -27,7 +27,7 @@ import java.net.HttpURLConnection;
|
|||||||
public class JdkClientEngine implements ClientEngine {
|
public class JdkClientEngine implements ClientEngine {
|
||||||
|
|
||||||
private ClientConfig config;
|
private ClientConfig config;
|
||||||
private HttpConnection conn;
|
private JdkHttpConnection conn;
|
||||||
/**
|
/**
|
||||||
* 重定向次数计数器,内部使用
|
* 重定向次数计数器,内部使用
|
||||||
*/
|
*/
|
||||||
@ -60,7 +60,7 @@ public class JdkClientEngine implements ClientEngine {
|
|||||||
* @param isAsync 是否异步,异步不会立即读取响应内容
|
* @param isAsync 是否异步,异步不会立即读取响应内容
|
||||||
* @return {@link Response}
|
* @return {@link Response}
|
||||||
*/
|
*/
|
||||||
public HttpResponse send(final Request message, final boolean isAsync) {
|
public JdkHttpResponse send(final Request message, final boolean isAsync) {
|
||||||
initConn(message);
|
initConn(message);
|
||||||
try {
|
try {
|
||||||
doSend(message);
|
doSend(message);
|
||||||
@ -116,15 +116,15 @@ public class JdkClientEngine implements ClientEngine {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 构建{@link HttpConnection}
|
* 构建{@link JdkHttpConnection}
|
||||||
*
|
*
|
||||||
* @param message {@link Request}消息
|
* @param message {@link Request}消息
|
||||||
* @return {@link HttpConnection}
|
* @return {@link JdkHttpConnection}
|
||||||
*/
|
*/
|
||||||
private HttpConnection buildConn(final Request message) {
|
private JdkHttpConnection buildConn(final Request message) {
|
||||||
final ClientConfig config = ObjUtil.defaultIfNull(this.config, ClientConfig::of);
|
final ClientConfig config = ObjUtil.defaultIfNull(this.config, ClientConfig::of);
|
||||||
|
|
||||||
final HttpConnection conn = HttpConnection
|
final JdkHttpConnection conn = JdkHttpConnection
|
||||||
.of(message.url().toURL(), config.getProxy())
|
.of(message.url().toURL(), config.getProxy())
|
||||||
.setConnectTimeout(config.getConnectionTimeout())
|
.setConnectTimeout(config.getConnectionTimeout())
|
||||||
.setReadTimeout(config.getReadTimeout())
|
.setReadTimeout(config.getReadTimeout())
|
||||||
@ -149,10 +149,10 @@ public class JdkClientEngine implements ClientEngine {
|
|||||||
* 调用转发,如果需要转发返回转发结果,否则返回{@code null}
|
* 调用转发,如果需要转发返回转发结果,否则返回{@code null}
|
||||||
*
|
*
|
||||||
* @param isAsync 最终请求是否异步
|
* @param isAsync 最终请求是否异步
|
||||||
* @return {@link HttpResponse},无转发返回 {@code null}
|
* @return {@link JdkHttpResponse},无转发返回 {@code null}
|
||||||
*/
|
*/
|
||||||
private HttpResponse sendRedirectIfPossible(final Request message, final boolean isAsync) {
|
private JdkHttpResponse sendRedirectIfPossible(final Request message, final boolean isAsync) {
|
||||||
final HttpConnection conn = this.conn;
|
final JdkHttpConnection conn = this.conn;
|
||||||
// 手动实现重定向
|
// 手动实现重定向
|
||||||
if (message.maxRedirectCount() > 0) {
|
if (message.maxRedirectCount() > 0) {
|
||||||
final int code;
|
final int code;
|
||||||
@ -176,7 +176,7 @@ public class JdkClientEngine implements ClientEngine {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 最终页面
|
// 最终页面
|
||||||
return new HttpResponse(this.conn, true, message.charset(), isAsync,
|
return new JdkHttpResponse(this.conn, true, message.charset(), isAsync,
|
||||||
isIgnoreResponseBody(message.method()));
|
isIgnoreResponseBody(message.method()));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -25,7 +25,7 @@ import java.util.Map;
|
|||||||
*
|
*
|
||||||
* @author Looly
|
* @author Looly
|
||||||
*/
|
*/
|
||||||
public class HttpConnection implements HeaderOperation<HttpConnection> {
|
public class JdkHttpConnection implements HeaderOperation<JdkHttpConnection> {
|
||||||
|
|
||||||
private final URL url;
|
private final URL url;
|
||||||
private final Proxy proxy;
|
private final Proxy proxy;
|
||||||
@ -38,7 +38,7 @@ public class HttpConnection implements HeaderOperation<HttpConnection> {
|
|||||||
* @param proxy 代理,无代理传{@code null}
|
* @param proxy 代理,无代理传{@code null}
|
||||||
* @return HttpConnection
|
* @return HttpConnection
|
||||||
*/
|
*/
|
||||||
public static HttpConnection of(final String urlStr, final Proxy proxy) {
|
public static JdkHttpConnection of(final String urlStr, final Proxy proxy) {
|
||||||
return of(URLUtil.toUrlForHttp(urlStr), proxy);
|
return of(URLUtil.toUrlForHttp(urlStr), proxy);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -49,8 +49,8 @@ public class HttpConnection implements HeaderOperation<HttpConnection> {
|
|||||||
* @param proxy 代理,无代理传{@code null}
|
* @param proxy 代理,无代理传{@code null}
|
||||||
* @return HttpConnection
|
* @return HttpConnection
|
||||||
*/
|
*/
|
||||||
public static HttpConnection of(final URL url, final Proxy proxy) {
|
public static JdkHttpConnection of(final URL url, final Proxy proxy) {
|
||||||
return new HttpConnection(url, proxy);
|
return new JdkHttpConnection(url, proxy);
|
||||||
}
|
}
|
||||||
|
|
||||||
// region --------------------------------------------------------------- Constructor
|
// region --------------------------------------------------------------- Constructor
|
||||||
@ -61,7 +61,7 @@ public class HttpConnection implements HeaderOperation<HttpConnection> {
|
|||||||
* @param url URL
|
* @param url URL
|
||||||
* @param proxy 代理
|
* @param proxy 代理
|
||||||
*/
|
*/
|
||||||
public HttpConnection(final URL url, final Proxy proxy) {
|
public JdkHttpConnection(final URL url, final Proxy proxy) {
|
||||||
this.url = url;
|
this.url = url;
|
||||||
this.proxy = proxy;
|
this.proxy = proxy;
|
||||||
|
|
||||||
@ -90,7 +90,7 @@ public class HttpConnection implements HeaderOperation<HttpConnection> {
|
|||||||
* @param method 请求方法
|
* @param method 请求方法
|
||||||
* @return 自己
|
* @return 自己
|
||||||
*/
|
*/
|
||||||
public HttpConnection setMethod(final Method method) {
|
public JdkHttpConnection setMethod(final Method method) {
|
||||||
if (Method.POST.equals(method) //
|
if (Method.POST.equals(method) //
|
||||||
|| Method.PUT.equals(method)//
|
|| Method.PUT.equals(method)//
|
||||||
|| Method.PATCH.equals(method)//
|
|| Method.PATCH.equals(method)//
|
||||||
@ -147,7 +147,7 @@ public class HttpConnection implements HeaderOperation<HttpConnection> {
|
|||||||
* @return this
|
* @return this
|
||||||
* @see HttpURLConnection#setUseCaches(boolean)
|
* @see HttpURLConnection#setUseCaches(boolean)
|
||||||
*/
|
*/
|
||||||
public HttpConnection setDisableCache(final boolean isDisableCache) {
|
public JdkHttpConnection setDisableCache(final boolean isDisableCache) {
|
||||||
this.conn.setUseCaches(!isDisableCache);
|
this.conn.setUseCaches(!isDisableCache);
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
@ -158,7 +158,7 @@ public class HttpConnection implements HeaderOperation<HttpConnection> {
|
|||||||
* @param timeout 超时
|
* @param timeout 超时
|
||||||
* @return this
|
* @return this
|
||||||
*/
|
*/
|
||||||
public HttpConnection setConnectTimeout(final int timeout) {
|
public JdkHttpConnection setConnectTimeout(final int timeout) {
|
||||||
if (timeout > 0 && null != this.conn) {
|
if (timeout > 0 && null != this.conn) {
|
||||||
this.conn.setConnectTimeout(timeout);
|
this.conn.setConnectTimeout(timeout);
|
||||||
}
|
}
|
||||||
@ -172,7 +172,7 @@ public class HttpConnection implements HeaderOperation<HttpConnection> {
|
|||||||
* @param timeout 超时
|
* @param timeout 超时
|
||||||
* @return this
|
* @return this
|
||||||
*/
|
*/
|
||||||
public HttpConnection setReadTimeout(final int timeout) {
|
public JdkHttpConnection setReadTimeout(final int timeout) {
|
||||||
if (timeout > 0 && null != this.conn) {
|
if (timeout > 0 && null != this.conn) {
|
||||||
this.conn.setReadTimeout(timeout);
|
this.conn.setReadTimeout(timeout);
|
||||||
}
|
}
|
||||||
@ -186,7 +186,7 @@ public class HttpConnection implements HeaderOperation<HttpConnection> {
|
|||||||
* @param timeout 超时时间
|
* @param timeout 超时时间
|
||||||
* @return this
|
* @return this
|
||||||
*/
|
*/
|
||||||
public HttpConnection setConnectionAndReadTimeout(final int timeout) {
|
public JdkHttpConnection setConnectionAndReadTimeout(final int timeout) {
|
||||||
setConnectTimeout(timeout);
|
setConnectTimeout(timeout);
|
||||||
setReadTimeout(timeout);
|
setReadTimeout(timeout);
|
||||||
|
|
||||||
@ -202,7 +202,7 @@ public class HttpConnection implements HeaderOperation<HttpConnection> {
|
|||||||
* @throws HttpException KeyManagementException和NoSuchAlgorithmException异常包装
|
* @throws HttpException KeyManagementException和NoSuchAlgorithmException异常包装
|
||||||
* @since 6.0.0
|
* @since 6.0.0
|
||||||
*/
|
*/
|
||||||
public HttpConnection setSSLInfo(final SSLInfo sslInfo) throws HttpException {
|
public JdkHttpConnection setSSLInfo(final SSLInfo sslInfo) throws HttpException {
|
||||||
final HttpURLConnection conn = this.conn;
|
final HttpURLConnection conn = this.conn;
|
||||||
|
|
||||||
if (conn instanceof HttpsURLConnection) {
|
if (conn instanceof HttpsURLConnection) {
|
||||||
@ -223,7 +223,7 @@ public class HttpConnection implements HeaderOperation<HttpConnection> {
|
|||||||
* @param blockSize 块大小(bytes数),0或小于0表示不设置Chuncked模式
|
* @param blockSize 块大小(bytes数),0或小于0表示不设置Chuncked模式
|
||||||
* @return this
|
* @return this
|
||||||
*/
|
*/
|
||||||
public HttpConnection setChunkedStreamingMode(final int blockSize) {
|
public JdkHttpConnection setChunkedStreamingMode(final int blockSize) {
|
||||||
if (blockSize > 0) {
|
if (blockSize > 0) {
|
||||||
conn.setChunkedStreamingMode(blockSize);
|
conn.setChunkedStreamingMode(blockSize);
|
||||||
}
|
}
|
||||||
@ -236,7 +236,7 @@ public class HttpConnection implements HeaderOperation<HttpConnection> {
|
|||||||
* @param isInstanceFollowRedirects 是否自定跳转
|
* @param isInstanceFollowRedirects 是否自定跳转
|
||||||
* @return this
|
* @return this
|
||||||
*/
|
*/
|
||||||
public HttpConnection setInstanceFollowRedirects(final boolean isInstanceFollowRedirects) {
|
public JdkHttpConnection setInstanceFollowRedirects(final boolean isInstanceFollowRedirects) {
|
||||||
conn.setInstanceFollowRedirects(isInstanceFollowRedirects);
|
conn.setInstanceFollowRedirects(isInstanceFollowRedirects);
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
@ -255,7 +255,7 @@ public class HttpConnection implements HeaderOperation<HttpConnection> {
|
|||||||
* @return HttpConnection
|
* @return HttpConnection
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public HttpConnection header(final String header, final String value, final boolean isOverride) {
|
public JdkHttpConnection header(final String header, final String value, final boolean isOverride) {
|
||||||
if (null != this.conn) {
|
if (null != this.conn) {
|
||||||
if (isOverride) {
|
if (isOverride) {
|
||||||
this.conn.setRequestProperty(header, value);
|
this.conn.setRequestProperty(header, value);
|
||||||
@ -296,7 +296,7 @@ public class HttpConnection implements HeaderOperation<HttpConnection> {
|
|||||||
* @return this
|
* @return this
|
||||||
* @throws IOException IO异常
|
* @throws IOException IO异常
|
||||||
*/
|
*/
|
||||||
public HttpConnection connect() throws IOException {
|
public JdkHttpConnection connect() throws IOException {
|
||||||
if (null != this.conn) {
|
if (null != this.conn) {
|
||||||
this.conn.connect();
|
this.conn.connect();
|
||||||
}
|
}
|
||||||
@ -309,7 +309,7 @@ public class HttpConnection implements HeaderOperation<HttpConnection> {
|
|||||||
* @return this
|
* @return this
|
||||||
* @since 4.6.0
|
* @since 4.6.0
|
||||||
*/
|
*/
|
||||||
public HttpConnection disconnectQuietly() {
|
public JdkHttpConnection disconnectQuietly() {
|
||||||
try {
|
try {
|
||||||
disconnect();
|
disconnect();
|
||||||
} catch (final Throwable e) {
|
} catch (final Throwable e) {
|
||||||
@ -324,7 +324,7 @@ public class HttpConnection implements HeaderOperation<HttpConnection> {
|
|||||||
*
|
*
|
||||||
* @return this
|
* @return this
|
||||||
*/
|
*/
|
||||||
public HttpConnection disconnect() {
|
public JdkHttpConnection disconnect() {
|
||||||
if (null != this.conn) {
|
if (null != this.conn) {
|
||||||
this.conn.disconnect();
|
this.conn.disconnect();
|
||||||
}
|
}
|
@ -16,7 +16,7 @@ import java.io.InputStream;
|
|||||||
*
|
*
|
||||||
* @author Looly
|
* @author Looly
|
||||||
*/
|
*/
|
||||||
public class HttpInputStream extends InputStream {
|
public class JdkHttpInputStream extends InputStream {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 原始流
|
* 原始流
|
||||||
@ -28,7 +28,7 @@ public class HttpInputStream extends InputStream {
|
|||||||
*
|
*
|
||||||
* @param response 响应对象
|
* @param response 响应对象
|
||||||
*/
|
*/
|
||||||
public HttpInputStream(final HttpResponse response) {
|
public JdkHttpInputStream(final JdkHttpResponse response) {
|
||||||
init(response);
|
init(response);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -78,7 +78,7 @@ public class HttpInputStream extends InputStream {
|
|||||||
*
|
*
|
||||||
* @param response 响应对象
|
* @param response 响应对象
|
||||||
*/
|
*/
|
||||||
private void init(final HttpResponse response) {
|
private void init(final JdkHttpResponse response) {
|
||||||
try {
|
try {
|
||||||
this.in = (response.status < HttpStatus.HTTP_BAD_REQUEST) ? response.httpConnection.getInputStream() : response.httpConnection.getErrorStream();
|
this.in = (response.status < HttpStatus.HTTP_BAD_REQUEST) ? response.httpConnection.getInputStream() : response.httpConnection.getErrorStream();
|
||||||
} catch (final IOException e) {
|
} catch (final IOException e) {
|
@ -27,7 +27,7 @@ import java.util.Map.Entry;
|
|||||||
*
|
*
|
||||||
* @author Looly
|
* @author Looly
|
||||||
*/
|
*/
|
||||||
public class HttpResponse implements Response, Closeable {
|
public class JdkHttpResponse implements Response, Closeable {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 请求时的默认编码
|
* 请求时的默认编码
|
||||||
@ -49,7 +49,7 @@ public class HttpResponse implements Response, Closeable {
|
|||||||
/**
|
/**
|
||||||
* 持有连接对象
|
* 持有连接对象
|
||||||
*/
|
*/
|
||||||
protected HttpConnection httpConnection;
|
protected JdkHttpConnection httpConnection;
|
||||||
/**
|
/**
|
||||||
* 响应状态码
|
* 响应状态码
|
||||||
*/
|
*/
|
||||||
@ -58,13 +58,13 @@ public class HttpResponse implements Response, Closeable {
|
|||||||
/**
|
/**
|
||||||
* 构造
|
* 构造
|
||||||
*
|
*
|
||||||
* @param httpConnection {@link HttpConnection}
|
* @param httpConnection {@link JdkHttpConnection}
|
||||||
* @param ignoreEOFError 是否忽略响应读取时可能的EOF异常
|
* @param ignoreEOFError 是否忽略响应读取时可能的EOF异常
|
||||||
* @param requestCharset 编码,从请求编码中获取默认编码
|
* @param requestCharset 编码,从请求编码中获取默认编码
|
||||||
* @param isAsync 是否异步
|
* @param isAsync 是否异步
|
||||||
* @param isIgnoreBody 是否忽略读取响应体
|
* @param isIgnoreBody 是否忽略读取响应体
|
||||||
*/
|
*/
|
||||||
protected HttpResponse(final HttpConnection httpConnection, final boolean ignoreEOFError, final Charset requestCharset, final boolean isAsync, final boolean isIgnoreBody) {
|
protected JdkHttpResponse(final JdkHttpConnection httpConnection, final boolean ignoreEOFError, final Charset requestCharset, final boolean isAsync, final boolean isIgnoreBody) {
|
||||||
this.httpConnection = httpConnection;
|
this.httpConnection = httpConnection;
|
||||||
this.ignoreEOFError = ignoreEOFError;
|
this.ignoreEOFError = ignoreEOFError;
|
||||||
this.requestCharset = requestCharset;
|
this.requestCharset = requestCharset;
|
||||||
@ -112,7 +112,7 @@ public class HttpResponse implements Response, Closeable {
|
|||||||
*
|
*
|
||||||
* @return this
|
* @return this
|
||||||
*/
|
*/
|
||||||
public HttpResponse sync() {
|
public JdkHttpResponse sync() {
|
||||||
if (null != this.body) {
|
if (null != this.body) {
|
||||||
this.body.sync();
|
this.body.sync();
|
||||||
}
|
}
|
||||||
@ -259,7 +259,7 @@ public class HttpResponse implements Response, Closeable {
|
|||||||
|
|
||||||
// 获取响应内容流
|
// 获取响应内容流
|
||||||
if (false == isIgnoreBody) {
|
if (false == isIgnoreBody) {
|
||||||
this.body = new ResponseBody(this, new HttpInputStream(this), isAsync, this.ignoreEOFError);
|
this.body = new ResponseBody(this, new JdkHttpInputStream(this), isAsync, this.ignoreEOFError);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// ---------------------------------------------------------------- Private method end
|
// ---------------------------------------------------------------- Private method end
|
@ -29,7 +29,7 @@ public class HtmlUtil {
|
|||||||
/**
|
/**
|
||||||
* script标签正则
|
* script标签正则
|
||||||
*/
|
*/
|
||||||
public static final Pattern RE_SCRIPT = Pattern.compile("<[\\s]*?script[^>]*?>.*?<[\\s]*?\\/[\\s]*?script[\\s]*?>", Pattern.CASE_INSENSITIVE);
|
public static final Pattern RE_SCRIPT = Pattern.compile("<\\s*?script[^>]*?>.*?<\\s*?/\\s*?script\\s*?>", Pattern.CASE_INSENSITIVE);
|
||||||
/**
|
/**
|
||||||
* 正则:匹配meta标签的编码信息
|
* 正则:匹配meta标签的编码信息
|
||||||
*/
|
*/
|
||||||
|
Loading…
x
Reference in New Issue
Block a user