Class: DDD::Associations::ManyCollection

Inherits:
Object
  • Object
show all
Extended by:
Forwardable
Includes:
Enumerable
Defined in:
lib/ddd-associations/many_collection.rb

Overview

Base class for has_many and has_and_belongs_to_many collections

Direct Known Subclasses

ManyToManyCollection, OneToManyCollection

Instance Method Summary collapse

Constructor Details

#initialize(one) ⇒ ManyCollection

one is what we are the collection for



14
15
16
17
# File 'lib/ddd-associations/many_collection.rb', line 14

def initialize(one)
  @one = one
  @many = Set.new
end