2024-02-17 06:35:49 +00:00
|
|
|
package condition
|
|
|
|
|
|
|
|
import (
|
|
|
|
"git.foosoft.net/alex/goldsmith"
|
|
|
|
)
|
|
|
|
|
|
|
|
type Condition struct {
|
|
|
|
accept bool
|
|
|
|
}
|
|
|
|
|
|
|
|
func New(accept bool) *Condition {
|
|
|
|
return &Condition{accept: accept}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (*Condition) Name() string {
|
|
|
|
return "condition"
|
|
|
|
}
|
|
|
|
|
2024-03-04 02:09:21 +00:00
|
|
|
func (self *Condition) Accept(file *goldsmith.File) bool {
|
2024-02-17 06:35:49 +00:00
|
|
|
return self.accept
|
|
|
|
}
|