Documentation ¶
Index ¶
- Variables
- func OrderedBy(less ...lessFunc) *multiSorter
- func Reset()
- type Accessor
- type CachingRepository
- func (c *CachingRepository) Close()
- func (c *CachingRepository) Delete(path string, node *Node) error
- func (c *CachingRepository) Export(ctx context.Context, cancelFunc context.CancelFunc, path string) (*Node, error)
- func (c *CachingRepository) Get(path string) (*Node, error)
- func (c *CachingRepository) GetChildren(path string) ([]*Node, error)
- func (c *CachingRepository) GetMeta(path string) (*goZk.Stat, error)
- func (c *CachingRepository) GetRootNode() (*Node, error)
- func (c *CachingRepository) GetValue(path string) (*Node, error)
- func (c *CachingRepository) Invalidate(path string)
- func (c *CachingRepository) InvalidateAll()
- func (c *CachingRepository) SaveChild(path string, child *Node) error
- func (c *CachingRepository) SaveValue(path string, node *Node) error
- func (c *CachingRepository) SetConnInfo(connInfo *core.ConnInfo)
- type CachingRepositoryAccessor
- type Node
- type Repository
- func (r *Repository) Close()
- func (r *Repository) Delete(path string, node *Node) error
- func (r *Repository) Get(path string) (*Node, error)
- func (r *Repository) GetChildren(path string) ([]*Node, error)
- func (r *Repository) GetMeta(path string) (*goZk.Stat, error)
- func (r *Repository) GetRootNode() (*Node, error)
- func (r *Repository) GetValue(path string) (*Node, error)
- func (r *Repository) Init(connInfo *core.ConnInfo)
- func (r *Repository) SaveChild(parentPath string, child *Node) error
- func (r *Repository) SaveValue(absPath string, node *Node) error
- func (r *Repository) SetConnInfo(connInfo *core.ConnInfo)
Constants ¶
This section is empty.
Variables ¶
View Source
var ( Repo = Repository{} CachingRepo = CachingRepository{Repo: Repo} )
View Source
var ConnCache goCache.LoadingCache
Functions ¶
Types ¶
type Accessor ¶
type Accessor interface { SetConnInfo(connInfo *core.ConnInfo) Get(path string) (*Node, error) //todo consider to remove next three methods and use Get instead GetMeta(path string) (*goZk.Stat, error) GetValue(path string) (*Node, error) GetChildren(path string) ([]*Node, error) GetRootNode() (*Node, error) SaveChild(parentPath string, childName string, acl []goZk.ACL) error SaveValue(parentPath string, node *Node) error Delete(path string, version int32) error Close() }
todo measure timings for each operation
type CachingRepository ¶
type CachingRepository struct { CachingRepositoryAccessor Repo Repository }
func (*CachingRepository) Close ¶
func (c *CachingRepository) Close()
func (*CachingRepository) Delete ¶
func (c *CachingRepository) Delete(path string, node *Node) error
func (*CachingRepository) Export ¶
func (c *CachingRepository) Export(ctx context.Context, cancelFunc context.CancelFunc, path string) (*Node, error)
func (*CachingRepository) GetChildren ¶
func (c *CachingRepository) GetChildren(path string) ([]*Node, error)
func (*CachingRepository) GetMeta ¶
func (c *CachingRepository) GetMeta(path string) (*goZk.Stat, error)
func (*CachingRepository) GetRootNode ¶
func (c *CachingRepository) GetRootNode() (*Node, error)
func (*CachingRepository) GetValue ¶
func (c *CachingRepository) GetValue(path string) (*Node, error)
func (*CachingRepository) Invalidate ¶
func (c *CachingRepository) Invalidate(path string)
func (*CachingRepository) InvalidateAll ¶
func (c *CachingRepository) InvalidateAll()
func (*CachingRepository) SaveChild ¶
func (c *CachingRepository) SaveChild(path string, child *Node) error
func (*CachingRepository) SaveValue ¶
func (c *CachingRepository) SaveValue(path string, node *Node) error
func (*CachingRepository) SetConnInfo ¶
func (c *CachingRepository) SetConnInfo(connInfo *core.ConnInfo)
type Repository ¶
type Repository struct { Accessor // contains filtered or unexported fields }
func (*Repository) Close ¶
func (r *Repository) Close()
func (*Repository) GetChildren ¶
func (r *Repository) GetChildren(path string) ([]*Node, error)
func (*Repository) GetRootNode ¶
func (r *Repository) GetRootNode() (*Node, error)
func (*Repository) Init ¶
func (r *Repository) Init(connInfo *core.ConnInfo)
func (*Repository) SetConnInfo ¶
func (r *Repository) SetConnInfo(connInfo *core.ConnInfo)
Click to show internal directories.
Click to hide internal directories.