1// This program is free software: you can redistribute it and/or modify 2// it under the terms of the GNU General Public License as published by 3// the Free Software Foundation, either version 3 of the License, or 4// (at your option) any later version. 5// 6// This program is distributed in the hope that it will be useful, 7// but WITHOUT ANY WARRANTY; without even the implied warranty of 8// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 9// GNU General Public License for more details.10//11// You should have received a copy of the GNU General Public License12// along with this program. If not, see <http://www.gnu.org/licenses/>.1314/*15Package feedparser implements a simple RSS and ATOM feed parser.1617Tho primary function of interest is the Parse function. You can pass an18arbitrary Reader to this function and it will return the corresponding19feed. The following demonstrates and example use case (reading a feed20from a file):2122 file, err := os.Open("feed.xml");23 if err != nil {24 panic(err)25 }26 defer file.Close()2728 feed, err := feedparser.Parse(file);29 if err != nil {30 panic(err)31 }3233 switch (feed.Type) {34 case "rss":35 fmt.Println("RSS feed!")36 case "atom":37 fmt.Println("ATOM feed!")38 default:39 fmt.Println("Unknown feed format")40 }41*/42package feedparser