Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BaseDocument ¶
type BaseDocument struct { Key string `json:"_key,omitempty"` ID DocumentID `json:"_id,omitempty"` Rev string `json:"_rev,omitempty"` }
BaseDocument is a minimal document for use in non-edge collection.
func NewBaseDocument ¶
func NewBaseDocument(meta *pbcmdb.Meta) *BaseDocument
type DocumentID ¶
type DocumentID string
DocumentID is a document ID Consists of two parts - collection name and key
func (DocumentID) Collection ¶
func (id DocumentID) Collection() string
Collection returns the collection part of the ID.
func (DocumentID) Parent ¶
func (id DocumentID) Parent() DocumentID
Parent - return parent's Document ID
func (DocumentID) ProfileName ¶
func (id DocumentID) ProfileName() string
ProfileName returns the profile name part of the ID.
func (DocumentID) String ¶
func (id DocumentID) String() string
type EdgeDocument ¶
type EdgeDocument struct { BaseDocument From DocumentID `json:"_from,omitempty"` To DocumentID `json:"_to,omitempty"` Type string `json:"_type,omitempty"` }
EdgeDocument is a minimal document for use in edge collection.
type Node ¶
type Node struct { Id DocumentID `json:"id,omitempty"` LinkId DocumentID `json:"link_id,omitempty"` Key string `json:"key,omitempty"` Name string `json:"name,omitempty"` Type string `json:"type,omitempty"` Object json.RawMessage `json:"object,omitempty"` Link json.RawMessage `json:"link,omitempty"` Path json.RawMessage `json:"path,omitempty"` }
Click to show internal directories.
Click to hide internal directories.