Module: Neo4j::ActiveNode::IdProperty::Accessor
- Extended by:
- ActiveSupport::Concern
- Included in:
- Neo4j::ActiveNode::IdProperty
- Defined in:
- lib/neo4j/active_node/id_property/accessor.rb
Overview
Provides get/set of the Id Property values. Some methods
Defined Under Namespace
Modules: ClassMethods
Instance Attribute Summary collapse
-
#default_property_value ⇒ Object
readonly
Returns the value of attribute default_property_value.
Instance Method Summary collapse
- #default_properties ⇒ Object
- #default_properties=(properties) ⇒ Object
- #default_property(key) ⇒ Object
- #default_property_key ⇒ Object
Instance Attribute Details
#default_property_value ⇒ Object (readonly)
Returns the value of attribute default_property_value.
7 8 9 |
# File 'lib/neo4j/active_node/id_property/accessor.rb', line 7 def default_property_value @default_property_value end |
Instance Method Details
#default_properties ⇒ Object
22 23 24 |
# File 'lib/neo4j/active_node/id_property/accessor.rb', line 22 def default_properties @default_properties ||= Hash.new(nil) end |
#default_properties=(properties) ⇒ Object
9 10 11 |
# File 'lib/neo4j/active_node/id_property/accessor.rb', line 9 def default_properties=(properties) @default_property_value = properties[default_property_key] end |
#default_property(key) ⇒ Object
13 14 15 16 |
# File 'lib/neo4j/active_node/id_property/accessor.rb', line 13 def default_property(key) return nil unless key == default_property_key default_property_value end |
#default_property_key ⇒ Object
18 19 20 |
# File 'lib/neo4j/active_node/id_property/accessor.rb', line 18 def default_property_key self.class.default_property_key end |