add vendoring

This commit is contained in:
Aine
2022-11-16 12:08:51 +02:00
parent 14751cbf3a
commit c1d33fe3cb
1104 changed files with 759066 additions and 0 deletions

29
vendor/github.com/jhillyerd/enmime/options.go generated vendored Normal file
View File

@@ -0,0 +1,29 @@
package enmime
// Option to configure parsing.
type Option interface {
apply(p *Parser)
}
// SkipMalformedParts sets parsing to skip parts that's can't be parsed.
func SkipMalformedParts(s bool) Option {
return skipMalformedPartsOption(s)
}
type skipMalformedPartsOption bool
func (o skipMalformedPartsOption) apply(p *Parser) {
p.skipMalformedParts = bool(o)
}
// MultipartWOBoundaryAsSinglePart if set to true will treat a multi-part messages without boundary parameter as single-part.
// Otherwise, will return error that boundary is not found.
func MultipartWOBoundaryAsSinglePart(a bool) Option {
return multipartWOBoundaryAsSinglePartOption(a)
}
type multipartWOBoundaryAsSinglePartOption bool
func (o multipartWOBoundaryAsSinglePartOption) apply(p *Parser) {
p.multipartWOBoundaryAsSinglePart = bool(o)
}