public class HttpConfig extends Object
Modifier and Type | Field and Description |
---|---|
static long |
DEFAULT_SESSION_TIMEOUT
session默认的超时时间,单位:秒
|
static int |
MAX_LENGTH_OF_BOUNDARY
文件上传时,boundary值的最大长度
|
static int |
MAX_LENGTH_OF_MULTI_BODY
文件上传时,体的最大长度
|
static int |
MAX_LENGTH_OF_MULTI_HEADER
文件上传时,头部的最大长度
|
static int |
MAX_LIVETIME_OF_STATICRES
默认的静态资源缓存时间,单位:秒
|
static String |
SESSION_CACHE_NAME
存放HttpSession对象的cacheName
|
static String |
SESSION_COOKIE_NAME
存放sessionId的cookie name
|
Constructor and Description |
---|
HttpConfig() |
HttpConfig(Integer bindPort,
Long sessionTimeout) |
public static final String SESSION_CACHE_NAME
public static final String SESSION_COOKIE_NAME
public static final long DEFAULT_SESSION_TIMEOUT
public static final int MAX_LIVETIME_OF_STATICRES
public static final int MAX_LENGTH_OF_BOUNDARY
public static final int MAX_LENGTH_OF_MULTI_HEADER
public static final int MAX_LENGTH_OF_MULTI_BODY
public static void main(String[] args)
args
- public String getBindIp()
public Integer getBindPort()
public String getCharset()
public int getMaxLiveTimeOfStaticRes()
public String getPage404()
public String getPage500()
public String getPageRoot()
public String getServerInfo()
public String getSessionCacheName()
public String getSessionCookieName()
public ISessionIdGenerator getSessionIdGenerator()
public org.tio.utils.cache.ICache getSessionStore()
public long getSessionTimeout()
public void setBindIp(String bindIp)
bindIp
- the bindIp to setpublic void setCharset(String charset)
charset
- the charset to setpublic void setMaxLiveTimeOfStaticRes(int maxLiveTimeOfStaticRes)
maxLiveTimeOfStaticRes
- the maxLiveTimeOfStaticRes to setpublic void setPage404(String page404)
public void setPage500(String page500)
public void setPageRoot(String pageRoot)
pageRoot
- public void setServerInfo(String serverInfo)
serverInfo
- the serverInfo to setpublic void setSessionCacheName(String sessionCacheName)
sessionCacheName
- the sessionCacheName to setpublic void setSessionCookieName(String sessionCookieName)
public void setSessionIdGenerator(ISessionIdGenerator sessionIdGenerator)
public void setSessionStore(org.tio.utils.cache.ICache sessionStore)
public IHttpRequestHandler getHttpRequestHandler()
public void setHttpRequestHandler(IHttpRequestHandler httpRequestHandler)
httpRequestHandler
- the httpRequestHandler to setpublic String[] getScanPackages()
public void setScanPackages(String[] scanPackages)
Copyright © 2018. All rights reserved.