subscription.go 745 B

12345678910111213141516171819202122
  1. // Copyright 2017 Frédéric Guillot. All rights reserved.
  2. // Use of this source code is governed by the Apache 2.0
  3. // license that can be found in the LICENSE file.
  4. package opml // import "miniflux.app/reader/opml"
  5. // Subcription represents a feed that will be imported or exported.
  6. type Subcription struct {
  7. Title string
  8. SiteURL string
  9. FeedURL string
  10. CategoryName string
  11. }
  12. // Equals compare two subscriptions.
  13. func (s Subcription) Equals(subscription *Subcription) bool {
  14. return s.Title == subscription.Title && s.SiteURL == subscription.SiteURL &&
  15. s.FeedURL == subscription.FeedURL && s.CategoryName == subscription.CategoryName
  16. }
  17. // SubcriptionList is a list of subscriptions.
  18. type SubcriptionList []*Subcription