Class: Outbrain::Api::Relation
- Inherits:
-
OpenStruct
- Object
- OpenStruct
- Outbrain::Api::Relation
- Extended by:
- Forwardable
- Includes:
- Enumerable
- Defined in:
- lib/outbrain/api/relation.rb
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ Relation
constructor
A new instance of Relation.
Constructor Details
#initialize(options = {}) ⇒ Relation
Returns a new instance of Relation.
7 8 9 10 11 12 13 |
# File 'lib/outbrain/api/relation.rb', line 7 def initialize( = {}) super self.errors = [] relation = .delete([:relation_name]) Hashie::Mash.new().each{ |k,v| self[k] = v } setup_relations(relation) end |