public abstract class DefaultAppBaseService extends AbstractBaseService
限定符和类型 | 字段和说明 |
---|---|
protected static org.apache.commons.configuration.Configuration |
config
配置项读取类
|
protected static String |
encoding
xml 或 json 响应的默认编码
|
EXCEPTION_MSG
log
DATA_TYPE_HTML, DATA_TYPE_JSON, DATA_TYPE_XML
构造器和说明 |
---|
DefaultAppBaseService() |
限定符和类型 | 方法和说明 |
---|---|
static org.apache.commons.configuration.Configuration |
getConfig() |
String |
getContentType()
返回数据 ContentType: html ?
|
protected String |
getJsonMsg(Boolean isSuccess,
String msg)
返回 json 格式的成功或错误信息
|
JsonRender |
getJsonRender()
返回转换 json 工具对象
|
protected String |
getXmlMsg(Boolean isSuccess,
String msg)
返回 chartXML 格式的成功或错误信息
|
XmlRender |
getXmlRender()
返回转换 xml 的工具对象
|
void |
output(javax.servlet.http.HttpServletResponse response,
String msg,
String contentType) |
fileExists, getFileName, handleRequest, handleRequest, handleRequest, handleRequest
protected static String encoding
protected static org.apache.commons.configuration.Configuration config
public static org.apache.commons.configuration.Configuration getConfig()
public String getContentType()
DataService
getContentType
在接口中 DataService
getContentType
在接口中 DownloadService
getContentType
在接口中 UploadService
getContentType
在类中 AbstractBaseService
public JsonRender getJsonRender()
public XmlRender getXmlRender()
public void output(javax.servlet.http.HttpServletResponse response, String msg, String contentType)
protected String getJsonMsg(Boolean isSuccess, String msg)
isSuccess
- true 表示成功消息 false 表示错误消息msg
- string which wants to convert to jsonCopyright © 2015 jiucai.org. All rights reserved.