Class: GenerativeUI::ComponentTreeValidator
- Inherits:
-
Object
- Object
- GenerativeUI::ComponentTreeValidator
- Defined in:
- lib/generative_ui/component_tree_validator.rb
Defined Under Namespace
Classes: Result
Constant Summary collapse
- TREE_KEY =
'_tree'- MAX_COMPONENTS =
500- MAX_DEPTH =
64- MAX_REFS =
2_000
Class Method Summary collapse
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(component_set, catalog) ⇒ ComponentTreeValidator
constructor
A new instance of ComponentTreeValidator.
Constructor Details
#initialize(component_set, catalog) ⇒ ComponentTreeValidator
Returns a new instance of ComponentTreeValidator.
18 19 20 21 22 23 |
# File 'lib/generative_ui/component_tree_validator.rb', line 18 def initialize(component_set, catalog) @component_set = component_set @catalog = catalog @errors = {} @edges = Hash.new { |hash, key| hash[key] = [] } end |
Class Method Details
.call(component_set, catalog:) ⇒ Object
14 15 16 |
# File 'lib/generative_ui/component_tree_validator.rb', line 14 def self.call(component_set, catalog:) new(component_set, catalog).call end |