boolrule API¶
BoolRule¶
-
class
boolrule.
BoolRule
(query, lazy=False)[source]¶ Represents a boolean expression and provides a test method to evaluate the expression and determine its truthiness.
Parameters: - query – A string containing the query to be evaluated
- lazy – If
True
, parse the query the first time it’s tested rather than immediately. This can help with performance if you instantiate a lot of rules and only end up evaluating a small handful.