Documentation ¶
Index ¶
- type Index
- func (index *Index) Add(item *model.Item)
- func (index *Index) GetAllChildren(route route.Route, expression func(item *model.Item) bool) []*model.Item
- func (index *Index) GetAllItems() []*model.Item
- func (index *Index) GetDirectChildren(route route.Route) []*model.Item
- func (index *Index) GetLeafes(route route.Route) []*model.Item
- func (index *Index) GetParent(childRoute route.Route) *model.Item
- func (index *Index) IsFileMatch(r route.Route) (*model.File, bool)
- func (index *Index) IsMatch(r route.Route) (item *model.Item, isMatch bool)
- func (index *Index) Remove(itemRoute route.Route)
- func (index *Index) Root() *model.Item
- func (index *Index) Size() int
- func (index *Index) String() string
- type ItemTree
- func (itemTree *ItemTree) Delete(itemRoute route.Route) (bool, error)
- func (itemTree *ItemTree) GetChildItems(route route.Route) []*model.Item
- func (itemTree *ItemTree) GetItem(route route.Route) *model.Item
- func (itemTree *ItemTree) Insert(item *model.Item)
- func (itemTree *ItemTree) Root() *model.Item
- func (itemTree *ItemTree) Walk(expression func(item *model.Item))
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Index ¶
type Index struct {
// contains filtered or unexported fields
}
func (*Index) GetAllChildren ¶
func (index *Index) GetAllChildren(route route.Route, expression func(item *model.Item) bool) []*model.Item
Get all children that match the given expression
func (*Index) GetAllItems ¶
GetAllItems returns all items in the index.
func (*Index) GetDirectChildren ¶
type ItemTree ¶
func (*ItemTree) GetChildItems ¶
Click to show internal directories.
Click to hide internal directories.