public abstract class AbstractWsController extends Object
| Modifier and Type | Field and Description |
|---|---|
protected org.springframework.context.ApplicationContext |
context |
protected static String |
LOG_SEPARATOR |
protected static org.apache.commons.logging.Log |
LOGGER |
protected static org.apache.commons.logging.Log |
STK_LOGGER |
| Constructor and Description |
|---|
AbstractWsController() |
| Modifier and Type | Method and Description |
|---|---|
protected org.springframework.http.ResponseEntity<String> |
logAndReturn(AbstractResponse result,
String query,
String user,
Long startTime,
ContentErrorCode error,
Object... args)
Default return method
If docs is null, return an empty response
|
protected org.springframework.http.ResponseEntity<String> |
logStackAndReturn(Exception e,
String query,
String user,
Long startTime,
ContentErrorCode error,
Object... args)
Return method with stacktrace
|
protected static final org.apache.commons.logging.Log LOGGER
protected static final org.apache.commons.logging.Log STK_LOGGER
protected static final String LOG_SEPARATOR
@Autowired protected org.springframework.context.ApplicationContext context
protected org.springframework.http.ResponseEntity<String> logAndReturn(AbstractResponse result, String query, String user, Long startTime, ContentErrorCode error, Object... args)
contents - some docsquery - method paramaters (for logging)startTime - start timeerror - the error codeargs - the error code argsprotected org.springframework.http.ResponseEntity<String> logStackAndReturn(Exception e, String query, String user, Long startTime, ContentErrorCode error, Object... args)
e - the exceptionparams - method paramaters (for logging)startTime - start timeerror - the error codeargs - the error code argsCopyright © 2022. All rights reserved.