Class ResourceFilter


  • @Evolving
    public class ResourceFilter
    extends Object
    A filter which matches Resource objects. The API for this class is still evolving and we may break compatibility in minor releases, if necessary.
    • Field Detail

    • Constructor Detail

      • ResourceFilter

        public ResourceFilter​(ResourceType resourceType,
                              String name)
        Create an instance of this class with the provided parameters.
        Parameters:
        resourceType - non-null resource type
        name - resource name or null
    • Method Detail

      • resourceType

        public ResourceType resourceType()
        Return the resource type.
      • name

        public String name()
        Return the resource name or null.
      • isUnknown

        public boolean isUnknown()
        Return true if this ResourceFilter has any UNKNOWN components.
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object
      • matches

        public boolean matches​(Resource other)
        Return true if this filter matches the given Resource.
      • matchesAtMostOne

        public boolean matchesAtMostOne()
        Return true if this filter could only match one ACE. In other words, if there are no ANY or UNKNOWN fields.
      • findIndefiniteField

        public String findIndefiniteField()
        Return a string describing an ANY or UNKNOWN field, or null if there is no such field.