Class: FeatureMeta
- Inherits:
-
Object
- Object
- FeatureMeta
- Defined in:
- lib/qspec_feature/feature_meta.rb
Instance Attribute Summary collapse
-
#id ⇒ Object
Returns the value of attribute id.
-
#name ⇒ Object
Returns the value of attribute name.
-
#scenarios ⇒ Object
Returns the value of attribute scenarios.
-
#versionId ⇒ Object
Returns the value of attribute versionId.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(id, name, scenarios, versionId) ⇒ FeatureMeta
constructor
A new instance of FeatureMeta.
- #to_json(options = {}) ⇒ Object
Constructor Details
#initialize(id, name, scenarios, versionId) ⇒ FeatureMeta
Returns a new instance of FeatureMeta.
4 5 6 7 8 9 |
# File 'lib/qspec_feature/feature_meta.rb', line 4 def initialize(id, name, scenarios, versionId) @id = id @name = name @scenarios = scenarios @versionId = versionId end |
Instance Attribute Details
#id ⇒ Object
Returns the value of attribute id.
2 3 4 |
# File 'lib/qspec_feature/feature_meta.rb', line 2 def id @id end |
#name ⇒ Object
Returns the value of attribute name.
2 3 4 |
# File 'lib/qspec_feature/feature_meta.rb', line 2 def name @name end |
#scenarios ⇒ Object
Returns the value of attribute scenarios.
2 3 4 |
# File 'lib/qspec_feature/feature_meta.rb', line 2 def scenarios @scenarios end |
#versionId ⇒ Object
Returns the value of attribute versionId.
2 3 4 |
# File 'lib/qspec_feature/feature_meta.rb', line 2 def versionId @versionId end |
Class Method Details
.from_json(data) ⇒ Object
15 16 17 |
# File 'lib/qspec_feature/feature_meta.rb', line 15 def self.from_json data self.new data['id'], data['name'], data['scenarios'], data['versionId'] end |
Instance Method Details
#to_json(options = {}) ⇒ Object
11 12 13 |
# File 'lib/qspec_feature/feature_meta.rb', line 11 def to_json(={}) {'id' => @id, 'name' => @name, 'scenarios' => @scenarios, 'versionId' => @versionId} end |