Method: Mongoid::Relations::Referenced::Many.path

Defined in:
lib/mongoid/relations/referenced/many.rb

.path(document) ⇒ Root

Get the path calculator for the supplied document.

Examples:

Get the path calculator.

Proxy.path(document)

Parameters:

  • document (Document)

    The document to calculate on.

Returns:

  • (Root)

    The root atomic path calculator.

Since:

  • 2.1.0



578
579
580
# File 'lib/mongoid/relations/referenced/many.rb', line 578

def path(document)
  Mongoid::Atomic::Paths::Root.new(document)
end