Module: Twitter::EasyClassMaker::ClassMethods
- Defined in:
- lib/twitter/easy_class_maker.rb
Class Method Summary collapse
-
.attributes ⇒ Object
read method for attributes class variable.
Instance Method Summary collapse
-
#attributes(*attrs) ⇒ Object
creates the attributes class variable and creates each attribute’s accessor methods.
Class Method Details
.attributes ⇒ Object
read method for attributes class variable
19 |
# File 'lib/twitter/easy_class_maker.rb', line 19 def self.attributes; @@attributes end |
Instance Method Details
#attributes(*attrs) ⇒ Object
creates the attributes class variable and creates each attribute’s accessor methods
13 14 15 16 |
# File 'lib/twitter/easy_class_maker.rb', line 13 def attributes(*attrs) @@attributes = attrs @@attributes.each { |a| attr_accessor a } end |