List of usage examples for javax.annotation Resource getClass
@HotSpotIntrinsicCandidate public final native Class<?> getClass();
From source file:com.cloudbees.clickstack.domain.metadata.Metadata.java
@Nonnull public <R extends Resource> Collection<R> getResources(@Nullable final Class<R> type) { if (type == null) return (Collection<R>) resources.values(); return (Collection<R>) Collections2.filter(resources.values(), new Predicate<Resource>() { @Override/*from ww w .j a v a2s. co m*/ public boolean apply(@Nullable Resource r) { return type.isAssignableFrom(r.getClass()); } }); }