/** * Factory method to create a predicated (validating) list. * <p> * If there are any elements already in the list being decorated, they * are validated. * * @param list the list to decorate, must not be null * @param predicate the predicate to use for validation, must not be null * @throws IllegalArgumentException if list or predicate is null * @throws IllegalArgumentException if the list contains invalid elements */ public static List decorate(List list, Predicate predicate) { return new PredicatedList(list, predicate); }
/** * Factory method to create a predicated (validating) list. * <p> * If there are any elements already in the list being decorated, they * are validated. * * @param list the list to decorate, must not be null * @param predicate the predicate to use for validation, must not be null * @throws IllegalArgumentException if list or predicate is null * @throws IllegalArgumentException if the list contains invalid elements */ public static List decorate(List list, Predicate predicate) { return new PredicatedList(list, predicate); }
public List subList(int fromIndex, int toIndex) { List sub = getList().subList(fromIndex, toIndex); return new PredicatedList(sub, predicate); }
/** * Factory method to create a typed list. * <p> * If there are any elements already in the list being decorated, they * are validated. * * @param list the list to decorate, must not be null * @param type the type to allow into the collection, must not be null * @throws IllegalArgumentException if list or type is null * @throws IllegalArgumentException if the list contains invalid elements */ public static List decorate(List list, Class type) { return new PredicatedList(list, InstanceofPredicate.getInstance(type)); }
public List subList(int fromIndex, int toIndex) { List sub = getList().subList(fromIndex, toIndex); return new PredicatedList(sub, predicate); }
/** * Factory method to create a typed list. * <p> * If there are any elements already in the list being decorated, they * are validated. * * @param list the list to decorate, must not be null * @param type the type to allow into the collection, must not be null * @throws IllegalArgumentException if list or type is null * @throws IllegalArgumentException if the list contains invalid elements */ public static List decorate(List list, Class type) { return new PredicatedList(list, InstanceofPredicate.getInstance(type)); }
/** * Factory method to create a predicated (validating) list. * <p> * If there are any elements already in the list being decorated, they * are validated. * * @param list the list to decorate, must not be null * @param predicate the predicate to use for validation, must not be null * @throws IllegalArgumentException if list or predicate is null * @throws IllegalArgumentException if the list contains invalid elements */ public static List decorate(List list, Predicate predicate) { return new PredicatedList(list, predicate); }
/** * Factory method to create a predicated (validating) list. * <p> * If there are any elements already in the list being decorated, they * are validated. * * @param list the list to decorate, must not be null * @param predicate the predicate to use for validation, must not be null * @throws IllegalArgumentException if list or predicate is null * @throws IllegalArgumentException if the list contains invalid elements */ public static List decorate(List list, Predicate predicate) { return new PredicatedList(list, predicate); }
/** * Factory method to create a predicated (validating) list. * <p> * If there are any elements already in the list being decorated, they * are validated. * * @param list the list to decorate, must not be null * @param predicate the predicate to use for validation, must not be null * @throws IllegalArgumentException if list or predicate is null * @throws IllegalArgumentException if the list contains invalid elements */ public static List decorate(List list, Predicate predicate) { return new PredicatedList(list, predicate); }
/** * Factory method to create a predicated (validating) list. * <p> * If there are any elements already in the list being decorated, they * are validated. * * @param list the list to decorate, must not be null * @param predicate the predicate to use for validation, must not be null * @throws IllegalArgumentException if list or predicate is null * @throws IllegalArgumentException if the list contains invalid elements */ public static List decorate(List list, Predicate predicate) { return new PredicatedList(list, predicate); }
/** * Factory method to create a predicated (validating) list. * <p> * If there are any elements already in the list being decorated, they * are validated. * * @param list the list to decorate, must not be null * @param predicate the predicate to use for validation, must not be null * @throws IllegalArgumentException if list or predicate is null * @throws IllegalArgumentException if the list contains invalid elements */ public static List decorate(List list, Predicate predicate) { return new PredicatedList(list, predicate); }
public List subList(int fromIndex, int toIndex) { List sub = getList().subList(fromIndex, toIndex); return new PredicatedList(sub, predicate); }
public List subList(int fromIndex, int toIndex) { List sub = getList().subList(fromIndex, toIndex); return new PredicatedList(sub, predicate); }
public List subList(int fromIndex, int toIndex) { List sub = getList().subList(fromIndex, toIndex); return new PredicatedList(sub, predicate); }
public List subList(int fromIndex, int toIndex) { List sub = getList().subList(fromIndex, toIndex); return new PredicatedList(sub, predicate); }
public List subList(int fromIndex, int toIndex) { List sub = getList().subList(fromIndex, toIndex); return new PredicatedList(sub, predicate); }
/** * Factory method to create a typed list. * <p> * If there are any elements already in the list being decorated, they * are validated. * * @param list the list to decorate, must not be null * @param type the type to allow into the collection, must not be null * @throws IllegalArgumentException if list or type is null * @throws IllegalArgumentException if the list contains invalid elements */ public static List decorate(List list, Class type) { return new PredicatedList(list, InstanceofPredicate.getInstance(type)); }
/** * Factory method to create a typed list. * <p> * If there are any elements already in the list being decorated, they * are validated. * * @param list the list to decorate, must not be null * @param type the type to allow into the collection, must not be null * @throws IllegalArgumentException if list or type is null * @throws IllegalArgumentException if the list contains invalid elements */ public static List decorate(List list, Class type) { return new PredicatedList(list, InstanceofPredicate.getInstance(type)); }
/** * Factory method to create a typed list. * <p> * If there are any elements already in the list being decorated, they * are validated. * * @param list the list to decorate, must not be null * @param type the type to allow into the collection, must not be null * @throws IllegalArgumentException if list or type is null * @throws IllegalArgumentException if the list contains invalid elements */ public static List decorate(List list, Class type) { return new PredicatedList(list, InstanceofPredicate.getInstance(type)); }
/** * Factory method to create a typed list. * <p> * If there are any elements already in the list being decorated, they * are validated. * * @param list the list to decorate, must not be null * @param type the type to allow into the collection, must not be null * @throws IllegalArgumentException if list or type is null * @throws IllegalArgumentException if the list contains invalid elements */ public static List decorate(List list, Class type) { return new PredicatedList(list, InstanceofPredicate.getInstance(type)); }