Module: DocWrapper::Properties
- Defined in:
- lib/doc_wrapper/properties.rb
Instance Attribute Summary collapse
-
#documents ⇒ Object
readonly
Returns the value of attribute documents.
Class Method Summary collapse
Instance Method Summary collapse
Instance Attribute Details
#documents ⇒ Object (readonly)
Returns the value of attribute documents.
4 5 6 |
# File 'lib/doc_wrapper/properties.rb', line 4 def documents @documents end |
Class Method Details
.included(base) ⇒ Object
6 7 8 9 10 11 12 13 |
# File 'lib/doc_wrapper/properties.rb', line 6 def self.included (base) base.extend(SattrAccessor) base.extend(ClassMethods) base.sattr_accessor :property_names base.sattr_accessor :property_definitions base.property_names = [] base.property_definitions = {} end |
Instance Method Details
#properties ⇒ Object
15 16 17 18 19 20 21 |
# File 'lib/doc_wrapper/properties.rb', line 15 def properties result = Hash.new property_names.each do |property| result[property] = send(property) end result end |