Module: Mongoid::Atomic::Paths::Embedded
Relationships & Source Files | |
Namespace Children | |
Classes:
| |
Extension / Inclusion / Inheritance Descendants | |
Included In:
| |
Defined in: | lib/mongoid/atomic/paths/embedded.rb, lib/mongoid/atomic/paths/embedded/many.rb, lib/mongoid/atomic/paths/embedded/one.rb |
Overview
Common functionality between the two different embedded paths.
Instance Attribute Summary
- #delete_modifier readonly
- #document readonly
- #insert_modifier readonly
- #parent readonly
Instance Method Summary
-
#path ⇒ String
Get the path to the document in the hierarchy.
Instance Attribute Details
#delete_modifier (readonly)
[ GitHub ]# File 'lib/mongoid/atomic/paths/embedded.rb', line 14
attr_reader :delete_modifier, :document, :insert_modifier, :parent
#document (readonly)
[ GitHub ]# File 'lib/mongoid/atomic/paths/embedded.rb', line 14
attr_reader :delete_modifier, :document, :insert_modifier, :parent
#insert_modifier (readonly)
[ GitHub ]# File 'lib/mongoid/atomic/paths/embedded.rb', line 14
attr_reader :delete_modifier, :document, :insert_modifier, :parent
#parent (readonly)
[ GitHub ]# File 'lib/mongoid/atomic/paths/embedded.rb', line 14
attr_reader :delete_modifier, :document, :insert_modifier, :parent
Instance Method Details
#path ⇒ String
Get the path to the document in the hierarchy.
# File 'lib/mongoid/atomic/paths/embedded.rb', line 22
def path @path ||= position.sub(/\.\d+\z/, "") end