use of core.framework.impl.web.ControllerClassValidator in project core-ng-project by neowu.
the class ModuleContext method route.
public void route(HTTPMethod method, String path, Controller controller, boolean skipInterceptor) {
new PathPatternValidator(path).validate();
ControllerInspector inspector = new ControllerInspector(controller);
new ControllerClassValidator(inspector.targetClass, inspector.targetMethod).validate();
String action = "http:" + ASCII.toLowerCase(method.name()) + ":" + path;
httpServer.handler.route.add(method, path, new ControllerHolder(controller, inspector.targetMethod, inspector.controllerInfo, action, skipInterceptor));
}
Aggregations