subscription.go 619 B

123456789101112131415161718192021
  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 subscription // import "miniflux.app/reader/subscription"
  5. import "fmt"
  6. // Subscription represents a feed subscription.
  7. type Subscription struct {
  8. Title string `json:"title"`
  9. URL string `json:"url"`
  10. Type string `json:"type"`
  11. }
  12. func (s Subscription) String() string {
  13. return fmt.Sprintf(`Title="%s", URL="%s", Type="%s"`, s.Title, s.URL, s.Type)
  14. }
  15. // Subscriptions represents a list of subscription.
  16. type Subscriptions []*Subscription