@SuppressWarnings({"unchecked", "rawtypes"}) public void execute( Environment env, Map params, TemplateModel[] loopVars, TemplateDirectiveBody body) throws TemplateException, IOException { List<Navigation> navigations; boolean useCache = useCache(env, params); String cacheRegion = getCacheRegion(env, params); Integer count = getCount(params); List<Filter> filters = getFilters(params, Navigation.class); List<Order> orders = getOrders(params); System.out.println("NavigationListDirective:" + useCache); if (useCache) { navigations = navigationService.findList(count, filters, orders, cacheRegion); } else { navigations = navigationService.findList(count, filters, orders); } setLocalVariable(VARIABLE_NAME, navigations, env, body); }