use of org.webpieces.router.impl.RouteMeta in project webpieces by deanhiller.
the class R1RouterBuilder method applyFilters.
private void applyFilters(L2DomainRoutes domainRoutes, WebAppMeta rm) {
String domain = domainRoutes.getDomain();
if (domain == null)
domain = "ALLOTHER";
RouteMeta notFoundMeta = domainRoutes.getPageNotFoundRoute();
RouteMeta internalErrorMeta = domainRoutes.getInternalSvrErrorRoute();
if (notFoundMeta == null)
throw new IllegalStateException("router.setNotFoundRoute MUST be called for domain=" + domain + " Modules=" + rm.getRouteModules());
else if (internalErrorMeta == null)
throw new IllegalStateException("router.setInternalSvrErrorRoute MUST be called for domain=" + domain + ". Modules=" + rm.getRouteModules());
internalErrorMeta.setFilters(internalErrorFilters);
notFoundMeta.setFilters(notFoundFilters);
}
Aggregations