public class PojoDispatcherImpl extends Object implements PojoDispatcher, Constants
| Modifier and Type | Field and Description |
|---|---|
protected Map<DispatchReq,DispatchTarget> |
mappings |
| Constructor and Description |
|---|
PojoDispatcherImpl(List<Object> controllers) |
| Modifier and Type | Method and Description |
|---|---|
protected Object |
complexArg(int i,
Class<?> type,
PojoRequest request,
String[] parts,
int paramsFrom,
int paramsSize) |
protected Object |
customSimpleArg(PojoRequest request,
Annotation[] annotations) |
DispatchResult |
dispatch(PojoRequest req) |
protected static PojoDispatchException |
error(Throwable cause,
String msg,
Object... args) |
protected List<String> |
getComponentNames(Class<?> component) |
protected Object |
getCustomArg(PojoRequest request,
Class<?> type,
String[] parts,
int paramsFrom,
int paramsSize) |
protected List<DispatchReq> |
getMethodActions(String componentPath,
Method method) |
protected Object |
invoke(PojoRequest req,
Method method,
Object component,
Object[] args) |
protected boolean |
isCustomSimpleArg(PojoRequest request,
Annotation[] annotations) |
protected boolean |
isCustomType(Class<?> type) |
protected static PojoHandlerNotFoundException |
notFound() |
protected Object |
postprocess(PojoRequest request,
Method method,
Object component,
Object[] args,
Object result) |
protected void |
preprocess(PojoRequest request,
Method method,
Object component,
Object[] args) |
protected DispatchResult |
process(PojoRequest req,
String command,
String path,
String[] parts,
int paramsFrom) |
protected final Map<DispatchReq,DispatchTarget> mappings
public DispatchResult dispatch(PojoRequest req) throws PojoHandlerNotFoundException, PojoDispatchException
dispatch in interface PojoDispatcherPojoHandlerNotFoundExceptionPojoDispatchExceptionprotected DispatchResult process(PojoRequest req, String command, String path, String[] parts, int paramsFrom) throws PojoHandlerNotFoundException, PojoDispatchException
protected Object invoke(PojoRequest req, Method method, Object component, Object[] args)
protected boolean isCustomSimpleArg(PojoRequest request, Annotation[] annotations)
protected Object customSimpleArg(PojoRequest request, Annotation[] annotations)
protected void preprocess(PojoRequest request, Method method, Object component, Object[] args)
protected Object postprocess(PojoRequest request, Method method, Object component, Object[] args, Object result)
protected Object complexArg(int i, Class<?> type, PojoRequest request, String[] parts, int paramsFrom, int paramsSize) throws PojoDispatchException
PojoDispatchExceptionprotected Object getCustomArg(PojoRequest request, Class<?> type, String[] parts, int paramsFrom, int paramsSize)
protected boolean isCustomType(Class<?> type)
protected List<DispatchReq> getMethodActions(String componentPath, Method method)
protected static PojoDispatchException error(Throwable cause, String msg, Object... args)
protected static PojoHandlerNotFoundException notFound()
Copyright © 2014–2015 Nikolche Mihajlovski and contributors. All rights reserved.