--- !ruby/object:RI::MethodDescription 
aliases: []

block_params: 
comment: 
- !ruby/struct:SM::Flow::P 
  body: A shorthand, clear syntax for defining many-to-one resource relationships.
- !ruby/struct:SM::Flow::VERB 
  body: " * belongs_to :user                              # many to one user\n * belongs_to :friend, :model =&gt; 'User'          # many to one friend\n * belongs_to :reference, :repository =&gt; :pubmed # association for repository other than default\n"
- !ruby/struct:SM::Flow::P 
  body: "@param name [Symbol]"
- !ruby/struct:SM::Flow::VERB 
  body: "  the name that the association will be referenced by\n"
- !ruby/struct:SM::Flow::P 
  body: "@param model [Model, #to_str]"
- !ruby/struct:SM::Flow::VERB 
  body: "  the target model of the relationship\n"
- !ruby/struct:SM::Flow::P 
  body: "@param opts [Hash]"
- !ruby/struct:SM::Flow::VERB 
  body: "  an options hash\n"
- !ruby/struct:SM::Flow::P 
  body: "@option :model[Model, String] The name of the class to associate with, if omitted"
- !ruby/struct:SM::Flow::VERB 
  body: "  then the association name is assumed to match the class name\n"
- !ruby/struct:SM::Flow::P 
  body: "@option :repository[Symbol]"
- !ruby/struct:SM::Flow::VERB 
  body: "  name of child model repository\n"
- !ruby/struct:SM::Flow::P 
  body: "@return [Association::Relationship] The association created"
- !ruby/struct:SM::Flow::VERB 
  body: "  should not be accessed directly\n"
- !ruby/struct:SM::Flow::P 
  body: "@api public"
full_name: DataMapper::Model::Relationship#belongs_to
is_singleton: false
name: belongs_to
params: (name, *args)
visibility: public
