Documentation ¶
Index ¶
- Constants
- func New(dir string) (api.Graph, error)
- type DB
- func (d *DB) AddNode(nodeType, nodeID string, properties map[string]interface{}) (api.Node, error)
- func (d *DB) Close() error
- func (d *DB) DelNode(nodeType, nodeID string) error
- func (d *DB) FSM() raft.FSM
- func (d *DB) GetNode(nodeType, nodeID string) (api.Node, error)
- func (d *DB) GetRelation(relation string, id string) (api.Relation, error)
- func (d *DB) NodeTypes() []string
- func (d *DB) RangeNodes(where *model.NodeWhere) (string, []api.Node, error)
- func (d *DB) RangeRelations(where *model.RelationWhere) (string, []api.Relation, error)
- func (d *DB) RelationTypes() []string
- type Node
- func (n Node) AddRelation(direction api.Direction, relation string, properties map[string]interface{}, ...) (api.Relation, error)
- func (n Node) DelProperty(name string) error
- func (n Node) DelRelation(relation string, id string) error
- func (n Node) GetProperty(name string) (interface{}, error)
- func (n Node) GetRelation(relation, id string) (api.Relation, bool, error)
- func (n Node) ID() string
- func (n Node) Properties() (map[string]interface{}, error)
- func (n Node) Relations(where *model.RelationWhere) (string, []api.Relation, error)
- func (n Node) SetProperties(properties map[string]interface{}) error
- func (n Node) Type() string
- type Relation
- func (n *Relation) DelProperty(name string) error
- func (r Relation) Direction() (api.Direction, error)
- func (n *Relation) GetProperty(name string) (interface{}, error)
- func (n *Relation) ID() string
- func (n *Relation) Properties() (map[string]interface{}, error)
- func (r Relation) Relation() (string, error)
- func (n *Relation) SetProperties(properties map[string]interface{}) error
- func (r Relation) Source() (api.Node, error)
- func (r Relation) Target() (api.Node, error)
- func (n *Relation) Type() string
Constants ¶
View Source
const ( Internal_ID = "_id" Internal_Type = "_type" Internal_Direction = "_direction" Internal_Relation = "_relation" Internal_SourceType = "_source_type" Internal_SourceID = "_source_id" Internal_TargetType = "_target_type" Internal_TargetID = "_target_id" )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type DB ¶
type DB struct {
// contains filtered or unexported fields
}
func (*DB) RangeRelations ¶
func (*DB) RelationTypes ¶
type Node ¶
type Node struct {
// contains filtered or unexported fields
}
func (Node) AddRelation ¶
func (Node) DelProperty ¶
func (Node) GetProperty ¶
func (Node) GetRelation ¶
func (Node) Properties ¶
func (Node) SetProperties ¶
type Relation ¶
type Relation struct {
// contains filtered or unexported fields
}
func (*Relation) DelProperty ¶
func (*Relation) GetProperty ¶
func (*Relation) Properties ¶
func (*Relation) SetProperties ¶
Click to show internal directories.
Click to hide internal directories.