Class: Dry::Schema::Compiler Private
- Inherits:
-
Logic::RuleCompiler
- Object
- Logic::RuleCompiler
- Dry::Schema::Compiler
- Defined in:
- lib/dry/schema/compiler.rb
Overview
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Extended rule compiler used internally by the DSL
Class Method Summary collapse
-
.new(predicates = PredicateRegistry.new) ⇒ Compiler
private
Builds a default compiler instance with custom predicate registry.
Instance Method Summary collapse
-
#supports?(predicate) ⇒ Boolean
private
Return true if a given predicate is supported by this compiler.
Class Method Details
.new(predicates = PredicateRegistry.new) ⇒ Compiler
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Builds a default compiler instance with custom predicate registry
15 16 17 |
# File 'lib/dry/schema/compiler.rb', line 15 def self.new(predicates = PredicateRegistry.new) super end |
Instance Method Details
#supports?(predicate) ⇒ Boolean
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Return true if a given predicate is supported by this compiler
26 27 28 |
# File 'lib/dry/schema/compiler.rb', line 26 def supports?(predicate) predicates.key?(predicate) end |