public Set<String> getBooleanConditions() { return ImmutableSet.copyOf(booleanConditions); }
options.scopeFiles = ImmutableSet.copyOf(set);
Set<String> orphanClassName) { if (matchAll) { return ImmutableSet.copyOf(styleClassesSet);
/** * Returns the tags passed to {@link #addTags}. */ synchronized Set<String> getTags() { return ImmutableSet.copyOf(tags); }
/** * Returns the tags passed to {@link #addTags}. */ synchronized Set<String> getTags() { return ImmutableSet.copyOf(tags); }
public Set<String> getBooleanConditions() { return ImmutableSet.copyOf(booleanConditions); }
static <A extends Annotation> ImmutableSet<Class<? extends ConstraintValidator<A, ?>>> // getValidatorForType(final Class<?> ptype, final List<Class<? extends ConstraintValidator<A, ?>>> constraintValidatorClasses) { final Class<?> type = Primitives.wrap(ptype); final Map<Class<?>, Class<? extends ConstraintValidator<A, ?>>> map = Maps.newHashMap(); for (final Class<? extends ConstraintValidator<A, ?>> conClass : constraintValidatorClasses) { final Class<?> aType = Primitives.wrap(getTypeOfConstraintValidator(conClass)); if (aType.isAssignableFrom(type)) { map.put(aType, conClass); } } // TODO(nchalko) implement per spec // Handle Arrays and Generics final Set<Class<?>> best = Util.findBestMatches(type, map.keySet()); final Predicate<Class<?>> inBest = key -> best.contains(key); return ImmutableSet.copyOf(Maps.filterKeys(map, inBest).values()); }
static <A extends Annotation> ImmutableSet<Class<? extends ConstraintValidator<A, ?>>> getValidatorForType( Class<?> type, List<Class<? extends ConstraintValidator<A, ?>>> constraintValidatorClasses) { type = Primitives.wrap(type); Map<Class<?>, Class<? extends ConstraintValidator<A, ?>>> map = Maps.newHashMap(); for (Class<? extends ConstraintValidator<A, ?>> constraintClass : constraintValidatorClasses) { Class<?> aType = Primitives.wrap(getTypeOfConstraintValidator(constraintClass)); if (aType.isAssignableFrom(type)) { map.put(aType, constraintClass); } } // TODO(nchalko) implement per spec // Handle Arrays and Generics final Set<Class<?>> best = Util.findBestMatches(type, map.keySet()); Predicate<Class<?>> inBest = new Predicate<Class<?>>() { @Override public boolean apply(Class<?> key) { return best.contains(key); } }; return ImmutableSet.copyOf(Maps.filterKeys(map, inBest).values()); }
static <A extends Annotation> ImmutableSet<Class<? extends ConstraintValidator<A, ?>>> getValidatorForType( Class<?> type, List<Class<? extends ConstraintValidator<A, ?>>> constraintValidatorClasses) { type = Primitives.wrap(type); Map<Class<?>, Class<? extends ConstraintValidator<A, ?>>> map = Maps.newHashMap(); for (Class<? extends ConstraintValidator<A, ?>> constraintClass : constraintValidatorClasses) { Class<?> aType = Primitives.wrap(getTypeOfConstraintValidator(constraintClass)); if (aType.isAssignableFrom(type)) { map.put(aType, constraintClass); } } // TODO(nchalko) implement per spec // Handle Arrays and Generics final Set<Class<?>> best = Util.findBestMatches(type, map.keySet()); Predicate<Class<?>> inBest = new Predicate<Class<?>>() { @Override public boolean apply(Class<?> key) { return best.contains(key); } }; return ImmutableSet.copyOf(Maps.filterKeys(map, inBest).values()); }
@Override public boolean setString(String str) { Splitter splitter = Splitter.on(",").omitEmptyStrings().trimResults(); shell.userAgentsOpt = ImmutableSet.copyOf(splitter.split(str)); return true; } });
@Override public boolean setString(String str) { Splitter splitter = Splitter.on(",").omitEmptyStrings().trimResults(); shell.userAgentsOpt = ImmutableSet.copyOf(splitter.split(str)); return true; } });
options.scopeFiles = ImmutableSet.copyOf(set);
Set<String> orphanClassName) { if (matchAll) { return ImmutableSet.copyOf(styleClassesSet);
Set<String> orphanClassName) { if (matchAll) { return ImmutableSet.copyOf(styleClassesSet);