Module: XRD::Properties

Included in:
Link, ResourceDescriptor
Defined in:
lib/xrd/properties.rb

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.included(base) ⇒ Object



6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# File 'lib/xrd/properties.rb', line 6

def self.included(base)
  base.send :include, SAXMachine
  base.send :elements, "Property", :as => :property_values
  base.send :elements, "Property", :as => :property_keys, :value => "type"
  base.send(:elements, "Property",
    :as => :property_nils, :value => "xsi:nil")

  base.send(:remove_method,
    :property_keys, :property_keys=, :add_property_keys
  )
  base.send(:remove_method,
    :property_values, :property_values=, :add_property_values
  )
  base.send(:remove_method,
    :property_nils, :property_nils=, :add_property_nils
  )
end

Instance Method Details

#propertiesObject



24
25
26
# File 'lib/xrd/properties.rb', line 24

def properties
  return @properties ||= []
end