Julien Riou
244c9f68e7
Filters are now separate structures to include a product or not based on their own set of properties. For now, include and exclude filters are supported. They take a regex as an argument and include a product if the regex matches (or doesn't match) the product name. This commit will allow us to create new filters on product like on a price range. Signed-off-by: Julien Riou <julien@riou.xyz>
6 lines
122 B
Go
6 lines
122 B
Go
package main
|
|
|
|
// Filter interface to include a product based on filters
|
|
type Filter interface {
|
|
Include(*Product) bool
|
|
}
|