Class | Mongoid::Relations::Builder |
In: |
lib/mongoid/relations/builder.rb
|
Parent: | Object |
Superclass for all builder objects. Builders are responsible for either looking up a relation‘s target from the database, or creating them from a supplied attributes hash.
base | [R] | |
metadata | [R] | |
object | [R] |
Instantiate the new builder for a relation.
@example Create the builder.
Builder.new(metadata, { :field => "value })
@param [ Document ] base The base document. @param [ Metdata ] metadata The metadata for the relation. @param [ Hash, BSON::ObjectId ] object The attributes to build from or
id to query with.
@since 2.0.0.rc.1