public class BaseResource extends Object
构造器和说明 |
---|
BaseResource() |
限定符和类型 | 方法和说明 |
---|---|
protected <T> T |
copyProperties(Map data,
T bean) |
protected String |
decode(String in) |
protected javax.ws.rs.core.Response |
error(Throwable e) |
protected javax.ws.rs.core.Response |
fail(String message) |
protected javax.ws.rs.core.Response |
fail(String message,
int code) |
protected com.seeyon.ctp.util.FlipInfo |
getFlipInfo() |
protected com.fasterxml.jackson.databind.ObjectMapper |
getObjectMapper() |
protected String |
getToken() |
protected <T> T |
judgeSortId(Map data,
com.seeyon.ctp.organization.bo.V3xOrgEntity bean)
判断当前对象是否设置了sortId,如果没有设置设置为NULL(因为创建对象判断根据NULL判断设置最大sortId)
|
protected javax.ws.rs.core.Response |
noContent() |
protected javax.ws.rs.core.Response |
ok(Object o)
已过时。
请使用success方法。
|
protected void |
required(Object o,
String fieldName) |
protected void |
required(Object o,
String[] fieldNames) |
protected void |
setCurrentUser(Long memberid)
设置当前人员
|
protected void |
setPagination() |
protected javax.ws.rs.core.Response |
status(int status) |
protected javax.ws.rs.core.Response |
status(int status,
Object entity) |
protected javax.ws.rs.core.Response |
success(Object o)
成功
|
protected javax.ws.rs.core.Response |
success(Object o,
String message) |
protected String |
toJSON(Object bean) |
protected String |
toJSON(Object bean,
String... ignoreProperties)
过滤指定属性列表。
|
protected javax.ws.rs.core.Response success(Object o)
o
- protected javax.ws.rs.core.Response fail(String message, int code)
protected javax.ws.rs.core.Response fail(String message)
protected javax.ws.rs.core.Response ok(Object o)
o
- protected javax.ws.rs.core.Response error(Throwable e)
protected javax.ws.rs.core.Response status(int status)
protected javax.ws.rs.core.Response status(int status, Object entity)
protected javax.ws.rs.core.Response noContent()
protected String getToken()
protected <T> T copyProperties(Map data, T bean)
protected String decode(String in) throws com.seeyon.ctp.common.exceptions.BusinessException
com.seeyon.ctp.common.exceptions.BusinessException
protected void required(Object o, String fieldName) throws com.seeyon.ctp.common.exceptions.BusinessException, IllegalAccessException, InvocationTargetException, NoSuchMethodException
com.seeyon.ctp.common.exceptions.BusinessException
IllegalAccessException
InvocationTargetException
NoSuchMethodException
protected void required(Object o, String[] fieldNames) throws com.seeyon.ctp.common.exceptions.BusinessException, IllegalAccessException, InvocationTargetException, NoSuchMethodException
com.seeyon.ctp.common.exceptions.BusinessException
IllegalAccessException
InvocationTargetException
NoSuchMethodException
protected void setPagination()
protected com.seeyon.ctp.util.FlipInfo getFlipInfo()
protected com.fasterxml.jackson.databind.ObjectMapper getObjectMapper()
protected String toJSON(Object bean, String... ignoreProperties)
bean
- ignoreProperties
- protected void setCurrentUser(Long memberid) throws com.seeyon.ctp.common.exceptions.BusinessException
memberid
- com.seeyon.ctp.common.exceptions.BusinessException
protected <T> T judgeSortId(Map data, com.seeyon.ctp.organization.bo.V3xOrgEntity bean)
Copyright © 2016–2017. All rights reserved.