module Ktistec::Rule

Defined in:

framework/rule.cr

Macro Summary

Macro Detail

macro make_pattern(name, clazz, associations = nil, properties = nil) #

Makes a pattern class given a model class.

Ktistec::Rule.make_pattern( RulePattern, RuleModel, associations: [child_of], properties: [id, name] )

In order to perform a match operation, pattern classes have to transform literals and bound values into the types the SQLite client library understands. This imposes constraints on types that participating model properties may use. In the example above, properties id and name must be one of the supported types.


[View source]