Class: Cucumber::Messages::PickleStep
- Defined in:
- lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-messages-18.0.0/lib/cucumber/messages.dtos.rb,
lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-messages-18.0.0/lib/cucumber/messages.deserializers.rb
Overview
Instance Attribute Summary collapse
-
#argument ⇒ Object
readonly
Returns the value of attribute argument.
-
#ast_node_ids ⇒ Object
readonly
References the IDs of the source of the step.
-
#id ⇒ Object
readonly
A unique ID for the PickleStep.
-
#text ⇒ Object
readonly
Returns the value of attribute text.
Class Method Summary collapse
-
.from_h(hash) ⇒ Object
Returns a new PickleStep from the given hash.
Instance Method Summary collapse
-
#initialize(argument: nil, ast_node_ids: [], id: '', text: '') ⇒ PickleStep
constructor
A new instance of PickleStep.
Methods included from Message::Utils
Methods included from Message::Serialization
Methods included from Message::Deserialization
Constructor Details
#initialize(argument: nil, ast_node_ids: [], id: '', text: '') ⇒ PickleStep
Returns a new instance of PickleStep.
1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 |
# File 'lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-messages-18.0.0/lib/cucumber/messages.dtos.rb', line 1180 def initialize( argument: nil, ast_node_ids: [], id: '', text: '' ) @argument = argument @ast_node_ids = ast_node_ids @id = id @text = text end |
Instance Attribute Details
#argument ⇒ Object (readonly)
Returns the value of attribute argument.
1165 1166 1167 |
# File 'lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-messages-18.0.0/lib/cucumber/messages.dtos.rb', line 1165 def argument @argument end |
#ast_node_ids ⇒ Object (readonly)
References the IDs of the source of the step. For Gherkin, this can be
the ID of a Step, and possibly also the ID of a TableRow
1171 1172 1173 |
# File 'lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-messages-18.0.0/lib/cucumber/messages.dtos.rb', line 1171 def ast_node_ids @ast_node_ids end |
#id ⇒ Object (readonly)
A unique ID for the PickleStep
1176 1177 1178 |
# File 'lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-messages-18.0.0/lib/cucumber/messages.dtos.rb', line 1176 def id @id end |
#text ⇒ Object (readonly)
Returns the value of attribute text.
1178 1179 1180 |
# File 'lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-messages-18.0.0/lib/cucumber/messages.dtos.rb', line 1178 def text @text end |
Class Method Details
.from_h(hash) ⇒ Object
Returns a new PickleStep from the given hash. If the hash keys are camelCased, they are properly assigned to the corresponding snake_cased attributes.
Cucumber::Messages::PickleStep.from_h(some_hash) # => #<Cucumber::Messages::PickleStep:0x... ...>
655 656 657 658 659 660 661 662 663 664 |
# File 'lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-messages-18.0.0/lib/cucumber/messages.deserializers.rb', line 655 def self.from_h(hash) return nil if hash.nil? self.new( argument: PickleStepArgument.from_h(hash[:argument]), ast_node_ids: hash[:astNodeIds], id: hash[:id], text: hash[:text], ) end |