searching

package
v0.0.0-...-8685a14 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 20, 2021 License: MIT Imports: 13 Imported by: 0

Documentation

Overview

Package wfs implements concurrent glob functionality with recursive "**" supports "**" in glob represents a recursive wildcard matching zero-or-more directory levels deep base on src: https://github.com/yargevad/filepathx/blob/master/filepathx.go todo: add rglob

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CGlob

func CGlob(ctx context.Context, wg *sync.WaitGroup, pattern string, cres chan<- string, cerr chan<- errs.Error)

CGlob - adapted version of Glob function from standard library (without ** support) to work in concurrent mode

Types

type Globs

type Globs []string

func (Globs) CExpand

func (globs Globs) CExpand(ctx context.Context, wg *sync.WaitGroup, cres chan<- string, cerr chan<- errs.Error)

CExpand is concurrent extention of standard Glob function with support **.

type Searcher

type Searcher interface {
	FoundFilePathsCh() <-chan string
	ErrCh() <-chan errs.Error
	Run(ctx context.Context) <-chan struct{}
	Stats() interface{}
}

func NewSearcher

func NewSearcher(ctx context.Context, roots []string, filePatterns []string, initCap int) Searcher

type SearcherStats

type SearcherStats registrator.Encounter

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL