public Collection<Filter> getAllFilters() { List<Filter> filters = new ArrayList<>(filterLibrary.entries()); if (parent != null) { filters.addAll(parent.getAllFilters()); } return filters; }
public Filter getFilter(String name) { Filter f = filterLibrary.getFilter(name); if (f != null) { return f; } if (parent != null) { return parent.getFilter(name); } return null; }
@SafeVarargs @SuppressWarnings("unchecked") public final void registerClasses(Class<? extends Importable>... classes) { for (Class<? extends Importable> c : classes) { if (ExpTest.class.isAssignableFrom(c)) { expTestLibrary.registerClasses((Class<? extends ExpTest>) c); } else if (Filter.class.isAssignableFrom(c)) { filterLibrary.registerClasses((Class<? extends Filter>) c); } else if (Tag.class.isAssignableFrom(c)) { tagLibrary.registerClasses((Class<? extends Tag>) c); } } }
public void registerFilter(Filter f) { filterLibrary.addFilter(f); }