atom/generator.go

19 lines
328 B
Go
Raw Normal View History

2024-10-13 17:19:40 +02:00
package atomfeed
import "errors"
type Generator struct {
*CommonAttributes
URI URI `xml:"uri,attr,omitempty"`
Version string `xml:"version,attr,omitempty"`
Text string `xml:"text"`
}
func (g *Generator) Check() error {
if g.Text == "" {
return errors.New("text element of generator empty")
}
return nil
}