module Neo4j::Model
Defined in:
neo4j/associations/belongs_to.crneo4j/associations/belongs_to_many.cr
neo4j/associations/has_many.cr
neo4j/associations/has_one.cr
neo4j/base.cr
neo4j/callbacks.cr
neo4j/persistence.cr
neo4j/querying.cr
neo4j/relationship.cr
neo4j/scopes.cr
neo4j/undeclared_properties.cr
neo4j/validation.cr
Constant Summary
-
ConnectionPool =
::ConnectionPool(Bolt::Connection).new(capacity: Neo4jModel.settings.pool_size) do Bolt::Connection.new(Neo4jModel.settings.neo4j_bolt_url, ssl: false) end
Instance Method Summary
- #[](key : Symbol | String) : Neo4j::Value | Nil
- #[]=(key : Symbol | String, val : Neo4j::Value) : Neo4j::Value
- #[]?(key : Symbol | String) : Neo4j::Value | Nil
- #errors
- #get(prop : String | Symbol) : Neo4j::Value | Nil
- #get_bool(prop : Symbol | String) : Bool | Nil
- #get_i(prop : Symbol | String) : Int32 | Nil
- #get_s(prop : String | Symbol) : String | Nil
-
#id : String | Nil
id works differently from uuid because sometimes presence of id is used like #persisted? but in our case, for various reasons, we assign a uuid even before the node is created
- #label : String
- #new_record? : Bool
- #persisted? : Bool
- #reload : Bool
- #save(*, skip_callbacks = false) : Bool
- #set(prop : String | Symbol, val : Neo4j::Value)
- #set_attributes(from node : Neo4j::Node) : Bool
- #set_attributes(hash : Hash(String, PropertyType)) : Bool
- #touch : Bool
- #update(hash : Hash(String, PropertyType)) : Bool
- #update(**params) : Bool
- #update_columns(hash : Hash(String, PropertyType)) : Bool
- #update_columns(**params) : Bool
- #uuid : String
- #valid?(*, skip_callbacks = false)
Macro Summary
-
belongs_to(klass, *, rel_type, name = "", plural = "", unique = true)
equivalent of ActiveNode has_one :in
-
belongs_to_many(klass, *, rel_type, name = "", unique = true)
equivalent of ActiveNode has_many :in
-
has_many(klass, *, rel_type, name = "", unique = true)
equivalent of ActiveNode has_many :out
-
has_one(klass, *, rel_type, name = "", plural = "", unique = true)
equivalent of ActiveNode has_one :out
- scope(name, proc)
Instance Method Detail
def id : String | Nil
#
id works differently from uuid because sometimes presence of id is used like #persisted? but in our case, for various reasons, we assign a uuid even before the node is created
Macro Detail
equivalent of ActiveNode has_one :in
equivalent of ActiveNode has_many :in
equivalent of ActiveNode has_many :out
equivalent of ActiveNode has_one :out