patternmatcher

package
v0.0.0-...-244c41e Latest Latest
Warning

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

Go to latest
Published: Mar 29, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Matcher

type Matcher interface {
	Matches(path string) bool
}

type PatternMatcher

type PatternMatcher struct {
	// contains filtered or unexported fields
}

PatternMatcher is a type that matches file names against excluded names

func NewMatcherFromReader

func NewMatcherFromReader(reader io.Reader) (*PatternMatcher, error)

NewMatcherFromReader creates a new ExcludesMatcher from a reader

func (*PatternMatcher) Matches

func (e *PatternMatcher) Matches(path string) bool

Matches tests whether a line matches one of the patterns to be excluded

type SimplePrefixMatcher

type SimplePrefixMatcher struct {
	Prefix string
}

func NewSimplePrefixMatcher

func NewSimplePrefixMatcher(prefix string) *SimplePrefixMatcher

func (*SimplePrefixMatcher) Matches

func (m *SimplePrefixMatcher) Matches(relativePath string) bool

Jump to

Keyboard shortcuts

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