public class EntityAttributesPredicate extends Object implements com.google.common.base.Predicate<EntityDescriptor>
EntityDescriptor
or its parent groups contain an
extension Attribute
that matches the predicate's criteria.Modifier and Type | Class and Description |
---|---|
static class |
EntityAttributesPredicate.Candidate
An object to encapsulate the set of criteria that must be satisfied by an
EntityAttributes
extension to satisfy the enclosing predicate. |
Constructor and Description |
---|
EntityAttributesPredicate(Collection<EntityAttributesPredicate.Candidate> candidates,
boolean trim)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
boolean |
apply(EntityDescriptor input) |
Collection<EntityAttributesPredicate.Candidate> |
getCandidates()
Get the candidate criteria.
|
boolean |
getTrimTags()
Get whether to trim tags for comparison.
|
public EntityAttributesPredicate(@Nonnull @NonnullElements Collection<EntityAttributesPredicate.Candidate> candidates, boolean trim)
candidates
- the EntityAttributesPredicate.Candidate
criteria to check fortrim
- true iff the values found in the metadata should be trimmed before comparisonpublic boolean getTrimTags()
@Nonnull @NonnullElements @Unmodifiable @NotLive public Collection<EntityAttributesPredicate.Candidate> getCandidates()
public boolean apply(@Nullable EntityDescriptor input)
apply
in interface com.google.common.base.Predicate<EntityDescriptor>
Copyright © 2017. All rights reserved.