Class: Igniter::Lang::MetadataCarrierManifest
- Inherits:
-
Object
- Object
- Igniter::Lang::MetadataCarrierManifest
- Defined in:
- lib/igniter/lang/metadata_carrier_manifest.rb
Constant Summary collapse
- KNOWN_SECTIONS =
%i[ diagnostics receipts model_validity_reports scenario_comparison_reports review_receipts ].freeze
- CUSTOM_SECTIONS_KEY =
:custom_sections- ENTRY_SEMANTICS =
{ report_only: true, runtime_enforced: false, raw_ref_export: false }.freeze
Instance Attribute Summary collapse
-
#sections ⇒ Object
readonly
Returns the value of attribute sections.
Class Method Summary collapse
Instance Method Summary collapse
- #empty? ⇒ Boolean
-
#initialize(sections: []) ⇒ MetadataCarrierManifest
constructor
A new instance of MetadataCarrierManifest.
- #to_h ⇒ Object
Constructor Details
#initialize(sections: []) ⇒ MetadataCarrierManifest
Returns a new instance of MetadataCarrierManifest.
28 29 30 31 |
# File 'lib/igniter/lang/metadata_carrier_manifest.rb', line 28 def initialize(sections: []) @sections = sections.map { |entry| deep_freeze(entry) }.freeze freeze end |
Instance Attribute Details
#sections ⇒ Object (readonly)
Returns the value of attribute sections.
22 23 24 |
# File 'lib/igniter/lang/metadata_carrier_manifest.rb', line 22 def sections @sections end |
Class Method Details
.from_metadata(metadata) ⇒ Object
24 25 26 |
# File 'lib/igniter/lang/metadata_carrier_manifest.rb', line 24 def self.() new(sections: build_sections()) end |
Instance Method Details
#empty? ⇒ Boolean
33 34 35 |
# File 'lib/igniter/lang/metadata_carrier_manifest.rb', line 33 def empty? sections.empty? end |
#to_h ⇒ Object
37 38 39 40 41 |
# File 'lib/igniter/lang/metadata_carrier_manifest.rb', line 37 def to_h { sections: sections } end |