• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..03-May-2022-

testdata/H07-Mar-2018-1,7901,707

LICENSEH A D07-Mar-2018234 64

README.mdH A D07-Mar-20181.6 KiB4027

atom.goH A D07-Mar-20182.9 KiB11496

author.goH A D07-Mar-201881 86

category.goH A D07-Mar-201871 75

channel.goH A D07-Mar-2018750 4136

cloud.goH A D07-Mar-2018165 108

content.goH A D07-Mar-201892 97

database.goH A D07-Mar-2018586 3426

databaseHandler.goH A D07-Mar-20181.1 KiB4640

enclosure.goH A D07-Mar-201886 86

feed.goH A D07-Mar-201810.3 KiB372212

feed_test.goH A D07-Mar-20185.9 KiB183147

generator.goH A D07-Mar-201890 86

image.goH A D07-Mar-2018152 119

input.goH A D07-Mar-2018118 97

item.goH A D07-Mar-2018893 5041

link.goH A D07-Mar-2018105 97

notes.mdH A D07-Mar-20186.2 KiB132107

rss.goH A D07-Mar-20186.5 KiB257216

source.goH A D07-Mar-201865 75

subtitle.goH A D07-Mar-201867 75

timeparser.goH A D07-Mar-2018625 3633

timeparser_test.goH A D07-Mar-20182.4 KiB9583

README.md

1# RSS
2
3This package allows us to fetch Rss and Atom feeds from the internet.
4They are parsed into an object tree which is a hybrid of both the RSS and Atom
5standards.
6
7Supported feeds are:
8- Rss v0.91, 0.92 and 2.0
9- Atom 1.0
10
11The package allows us to maintain cache timeout management. This prevents us
12from querying the servers for feed updates too often and risk ip bans. Apart
13from setting a cache timeout manually, the package also optionally adheres to
14the TTL, SkipDays and SkipHours values specified in the feeds themselves.
15
16Note that the TTL, SkipDays and SkipHour fields are only part of the RSS spec.
17For Atom feeds, we use the CacheTimeout in the Feed struct.
18
19Because the object structure is a hybrid between both RSS and Atom specs, not
20all fields will be filled when requesting either an RSS or Atom feed. I have
21tried to create as many shared fields as possible but some of them simply do
22not occur in either the RSS or Atom spec.
23
24The Feed object supports notifications of new channels and items.
25This is achieved by passing 2 function handlers to the feeder.New() function.
26They will be called whenever a feed is updated from the remote source and
27either a new channel or a new item is found that previously did not exist.
28This allows you to easily monitor a feed for changes. See feed_test.go for
29an example of how this works.
30
31## DEPENDENCIES
32
33[github.com/jteeuwen/go-pkg-xmlx](http://github.com/jteeuwen/go-pkg-xmlx)
34
35## USAGE
36
37
38An idiomatic example program can be found in [testdata/example.go](https://github.com/jteeuwen/go-pkg-rss/blob/master/testdata/example.go).
39
40