2019-06-27 19:33:12 +02:00
|
|
|
package lib
|
|
|
|
|
|
|
|
type DirStore struct {
|
|
|
|
dirs []string
|
|
|
|
}
|
|
|
|
|
|
|
|
func NewDirStore() *DirStore {
|
2019-07-04 18:31:27 +02:00
|
|
|
return &DirStore{}
|
2019-06-27 19:33:12 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
func (store *DirStore) Update(dirs []string) {
|
|
|
|
store.dirs = make([]string, len(dirs))
|
|
|
|
copy(store.dirs, dirs)
|
|
|
|
}
|
|
|
|
|
|
|
|
func (store *DirStore) List() []string {
|
|
|
|
return store.dirs
|
|
|
|
}
|