Class: Lutaml::Model::Schema::Definitions::Choice
- Inherits:
-
Object
- Object
- Lutaml::Model::Schema::Definitions::Choice
- Defined in:
- lib/lutaml/model/schema/definitions/choice.rb
Overview
A choice do ... end block. Alternatives may be Attribute,
Sequence, or nested Choice specs.
Instance Attribute Summary collapse
-
#alternatives ⇒ Object
Returns the value of attribute alternatives.
-
#header ⇒ Object
Returns the value of attribute header.
Instance Method Summary collapse
-
#initialize(alternatives:, header:) ⇒ Choice
constructor
A new instance of Choice.
Constructor Details
#initialize(alternatives:, header:) ⇒ Choice
Returns a new instance of Choice.
12 13 14 15 |
# File 'lib/lutaml/model/schema/definitions/choice.rb', line 12 def initialize(alternatives:, header:) @alternatives = alternatives @header = header end |
Instance Attribute Details
#alternatives ⇒ Object
Returns the value of attribute alternatives.
10 11 12 |
# File 'lib/lutaml/model/schema/definitions/choice.rb', line 10 def alternatives @alternatives end |
#header ⇒ Object
Returns the value of attribute header.
10 11 12 |
# File 'lib/lutaml/model/schema/definitions/choice.rb', line 10 def header @header end |