- Index
- »
- fan.haystack
- »
- Filter
Filter
@Js
const abstract class Filter : Obj
Filter models a declarative predicate for selecting dicts. See Filters for details.
Parse a query from string - see Filters for format
Return the normalized string of the filter
Equality is based on the normalized string
Return if the specified record matches this filter
Hash is based on toStr
virtual Bool equals(Obj? that)
Equality is based on the normalized string.
static new fromStr(Str s, Bool checked)
Parse a query from string - see Filters for format. If the query cannot be parsed then return null or throw ParseErr with location of error.
virtual Int hash()
Hash is based on toStr.
Bool matches(Dict r, HaystackContext? cx)
Return if the specified record matches this filter. Pass a context object to enable def aware features and to path through refs via the -> operator.
abstract Str toStr()
Return the normalized string of the filter