Filter class

An LDAP search filter.

An LDAP search filter can be a single filter created using either of these factory methods:

  • present - matches if the entry contains the attribute
  • equals - matches if an attribute has a given value
  • substring - matches wildcard
  • approx - matches if an attribute approximately has the value
  • greaterOrEquals - matches if the value is greater than or equal
  • lessOrEquals - matches if the entry has the attribute with a value that is less than or equal to the supplied value

Or it can be a compound filter that composes other filters created using these factory methods:

  • not - matches if its member filter does not match
  • and - matches if all of its member filters match
  • or - matches if at least one of its member filters match
Implementers

Constructors

Filter(int _filterType, [String? _attributeName, String? _assertionValue, List<Filter> _subFilters = const []])
Constructor

Properties

assertionValue String?
no setter
attributeName String?
no setter
filterType int
no setter
hashCode int
The hash code for this object.
no setteroverride
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
subFilters List<Filter>
no setter

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toASN1() → ASN1Object
Convert a Filter expression to an ASN1 Object This may be called recursively
toString() String
A string representation of this object.
override

Operators

operator &(Filter other) Filter
Operator version of the and filter factory method.
operator ==(Object other) bool
The equality operator.
override
operator |(Filter other) Filter
Operator version of the or filter factory method.

Static Methods

and(List<Filter> filters) Filter
Creates a Filter that matches entries that matches all of the filters.
approx(String attributeName, String attrValue) Filter
Creates a Filter that matches an entry that contains the attributeName that approximately matches attrValue.
equals(String attributeName, String attrValue) Filter
Creates a Filter that matches an entry that has an attribute with the given value.
greaterOrEquals(String attributeName, String attrValue) Filter
Creates a Filter that matches an entry that contains the attributeName with a value that is greater than or equal to attrValue.
lessOrEquals(String attributeName, String attrValue) Filter
Creates a Filter that matches an entry that contains the attributeName with a value that is less than or equal to attrValue.
not(Filter f) Filter
Creates a Filter that matches entries that don't match on f.
or(List<Filter> filters) Filter
Creates a Filter that matches entries that matches at least one of the filters.
present(String attrName) Filter
Creates a Filter that matches an entry contains an attribute.
substring(String attribute, String pattern) Filter
Creates a Filter that matches on a substring.