Documentation
¶
Index ¶
- Variables
- type Box
- func (d *Box) DeleteGroup(name string) error
- func (d *Box) DeleteGroupWithRelated(name string) error
- func (d *Box) DeleteSet(key string) error
- func (d *Box) GetGroups() []string
- func (d *Box) GetLastKey() string
- func (d *Box) GetMainKey() (string, error)
- func (d *Box) GetSet(key string) (Note, error)
- func (d *Box) ListAllKeys() []string
- func (d *Box) ListSetWithHiddenContent() []SetViewWithoutContent
- func (d *Box) ListSets() []SetView
- func (d *Box) MainAlreadyExists() bool
- func (d *Box) ModifyBox(box BoxData)
- func (d *Box) ModifyGroupName(oldName, newName string) error
- func (d *Box) ModifySetContent(key string, content string) error
- func (d *Box) ModifySetTag(key string, tag string) error
- func (d *Box) ModifySetType(key string, sType string) error
- func (d *Box) NewFromSet(set Note) (string, error)
- func (d *Box) NewGroup(name string) error
- func (d *Box) NewSet(content, contentType string) (string, error)
- func (d *Box) NewSetWithTag(content, contentType, tag string) (string, error)
- func (d *Box) NewSetsFromOutside(sets []Note) ([]string, error)
- func (d *Box) OverwriteSet(key string, set Note) error
- func (d *Box) SearchSetByKeyPattern(pattern string) (string, Note, error)
- func (d *Box) SearchSetByKeyTagPattern(pattern string) (string, Note, error)
- func (d *Box) TagAlreadyExists(tag string) bool
- type BoxData
- type Changes
- type Note
- type SetModifier
- type SetView
- type SetViewWithoutContent
- type Window
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrMainAlreadyExists error = errors.New("main set already exists") ErrGroupAlreadyExists error = errors.New("group already exists") ErrMainSetNotFound error = errors.New("main set not found") ErrTagAlreadyExists error = errors.New("tag already exists") ErrGroupNotFound error = errors.New("group not found") ErrTagNotProvided error = errors.New("tag not provided") ErrInvalidSetType error = errors.New("invalid set type") ErrSetNotFound error = errors.New("set not found") )
Functions ¶
This section is empty.
Types ¶
type Box ¶
type Box struct {
// contains filtered or unexported fields
}
func (*Box) DeleteGroup ¶ added in v0.9.0
func (*Box) DeleteGroupWithRelated ¶ added in v0.9.0
func (*Box) GetLastKey ¶
func (*Box) GetMainKey ¶
func (*Box) ListAllKeys ¶
func (*Box) ListSetWithHiddenContent ¶
func (d *Box) ListSetWithHiddenContent() []SetViewWithoutContent
func (*Box) MainAlreadyExists ¶
func (*Box) ModifyGroupName ¶ added in v0.9.0
func (*Box) ModifySetContent ¶ added in v0.2.0
func (*Box) ModifySetType ¶ added in v0.8.4
func (*Box) NewSetWithTag ¶
func (*Box) SearchSetByKeyPattern ¶
func (*Box) SearchSetByKeyTagPattern ¶
func (*Box) TagAlreadyExists ¶
type BoxData ¶
type BoxData struct {
LastAccess string `json:"lastSet"`
NaoSet map[string]Note `json:"naoSet"`
Groups []string `json:"groups"`
}
func JustLoadBox ¶ added in v0.0.6
func JustLoadBox() BoxData
type Note ¶ added in v0.9.0
type Note struct {
Tag string `json:"tag,omitempty"`
Type string `json:"type"`
Group string `json:"group"`
Content string `json:"content"`
Extension string `json:"extension,omitempty"`
Changes Changes `json:"changes"`
Title string `json:"title,omitempty"`
LastUpdate time.Time `json:"lastUpdate"`
Version int `json:"version"`
}
type SetModifier ¶ added in v0.8.4
type SetViewWithoutContent ¶
Click to show internal directories.
Click to hide internal directories.