matcher

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Oct 13, 2017 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CompositeInterface

type CompositeInterface interface {
	Add(child CompositeInterface)
}

type CompositeMatcher

type CompositeMatcher struct {
	CompositeInterface
	MatcherInterface
	// contains filtered or unexported fields
}

func NewCompositeMatcher

func NewCompositeMatcher() *CompositeMatcher

func (*CompositeMatcher) Add

func (f *CompositeMatcher) Add(child MatcherInterface)

func (*CompositeMatcher) Matches

func (f *CompositeMatcher) Matches(subject interface{}) bool

type FileAgeMatcher

type FileAgeMatcher struct {
	MatcherInterface
	Fs afero.Fs
	// contains filtered or unexported fields
}

func NewFileAgeMatcher

func NewFileAgeMatcher(minAge, maxAge time.Time) *FileAgeMatcher

func (*FileAgeMatcher) Matches

func (faMatcher *FileAgeMatcher) Matches(subject interface{}) bool

type FileSizeMatcher

type FileSizeMatcher struct {
	MatcherInterface
	Fs afero.Fs
	// contains filtered or unexported fields
}

func NewFileSizeMatcher

func NewFileSizeMatcher(minSize, maxSize int64) *FileSizeMatcher

func (*FileSizeMatcher) Matches

func (fsMatcher *FileSizeMatcher) Matches(subject interface{}) bool

type MatcherInterface

type MatcherInterface interface {
	Matches(pattern interface{}) bool
}

type RegexMatcher

type RegexMatcher struct {
	MatcherInterface
	// contains filtered or unexported fields
}

func NewRegexMatcher

func NewRegexMatcher(regex *regexp.Regexp) *RegexMatcher

func (*RegexMatcher) Matches

func (f *RegexMatcher) Matches(subject interface{}) bool

Jump to

Keyboard shortcuts

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