Class: ONIX::ResourceVersionFeature
- Defined in:
- lib/onix/resource_version_feature.rb
Instance Attribute Summary
Attributes included from Attributes
Low level collapse
- #feature_notes ⇒ Array<String>
- #feature_value ⇒ String
- #resource_version_feature_type ⇒ ResourceVersionFeatureType
Shortcuts collapse
-
#notes ⇒ Array<String>
shortcut for #feature_notes.
-
#type ⇒ ResourceVersionFeatureType
shortcut for #resource_version_feature_type.
-
#value ⇒ String
shortcut for #feature_value.
Instance Method Summary collapse
Methods inherited from SubsetDSL
element, elements, #get_class, get_class, inherited, #initialize, n, ref_to_short, register_elements, register_scopes, #register_subset_array, registered_elements, #registered_elements, registered_scopes, scope, short_to_ref
Methods inherited from Subset
parse, #tag_match, #unsupported
Methods included from Attributes
attribute_class, #parse_attributes, #serialized_attributes
Constructor Details
This class inherits a constructor from ONIX::SubsetDSL
Instance Method Details
#feature_notes ⇒ Array<String>
4 |
# File 'lib/onix/resource_version_feature.rb', line 4 elements "FeatureNote", :text, :shortcut => :notes, :cardinality => 0..n |
#feature_value ⇒ String
5 6 7 8 |
# File 'lib/onix/resource_version_feature.rb', line 5 element "FeatureValue", :text, { :shortcut => :value, :serialize_lambda => lambda { |v| v.class == SupportingResourceFileFormat ? v.code : v } } |
#notes ⇒ Array<String>
shortcut for #feature_notes
4 |
# File 'lib/onix/resource_version_feature.rb', line 4 elements "FeatureNote", :text, :shortcut => :notes, :cardinality => 0..n |
#parse(n) ⇒ Object
14 15 16 17 18 19 20 |
# File 'lib/onix/resource_version_feature.rb', line 14 def parse(n) super if @resource_version_feature_type.human == "FileFormat" @feature_value = SupportingResourceFileFormat.from_code(@feature_value) end end |
#resource_version_feature_type ⇒ ResourceVersionFeatureType
3 |
# File 'lib/onix/resource_version_feature.rb', line 3 element "ResourceVersionFeatureType", :subset, :shortcut => :type, :cardinality => 1 |
#type ⇒ ResourceVersionFeatureType
shortcut for #resource_version_feature_type
3 |
# File 'lib/onix/resource_version_feature.rb', line 3 element "ResourceVersionFeatureType", :subset, :shortcut => :type, :cardinality => 1 |
#value ⇒ String
shortcut for #feature_value
5 6 7 8 |
# File 'lib/onix/resource_version_feature.rb', line 5 element "FeatureValue", :text, { :shortcut => :value, :serialize_lambda => lambda { |v| v.class == SupportingResourceFileFormat ? v.code : v } } |