Class: Textus::Container
- Inherits:
-
Dry::Struct
- Object
- Dry::Struct
- Textus::Container
- Defined in:
- lib/textus/container.rb
Overview
Single capability record handed to every use case. Replaces the ReadCaps/WriteCaps/HookCaps trio from 0.26.x. Built once per Store (see Store#initialize); Store delegates its readers to this record, so this struct is the single source of truth for the field set.
Instance Method Summary collapse
-
#initialize ⇒ Container
constructor
A new instance of Container.
- #with(**attrs) ⇒ Object
Constructor Details
#initialize ⇒ Container
Returns a new instance of Container.
21 22 23 24 |
# File 'lib/textus/container.rb', line 21 def initialize(*) super freeze end |
Instance Method Details
#with(**attrs) ⇒ Object
19 |
# File 'lib/textus/container.rb', line 19 def with(**attrs) = self.class.new(to_h.merge(attrs)) |