From 0bd157918bfd0a8e647731600353c0e9428780ea Mon Sep 17 00:00:00 2001 From: mishako Date: Mon, 10 Oct 2016 22:08:16 +0200 Subject: [PATCH 1/6] Remove rome-parent from modules list in readme It's a common practice for maven projects to have a parent module and is not important enough to include information about it in readme. --- README.md | 1 - 1 file changed, 1 deletion(-) diff --git a/README.md b/README.md index 356b7c2..4c11ab0 100644 --- a/README.md +++ b/README.md @@ -7,7 +7,6 @@ ROME is a Java framework for RSS and Atom feeds. The framework consist of severa | Module | Description | | ------ | ----------- | -| rome-parent | is the parent project for all ROME modules and contains the common Maven configuration. | | rome-utils | provides utility classes that are used in several ROME modules. | | rome | is the main RSS and Atom library. It makes it easy to work with most syndication formats: RSS 0.90, RSS 0.91 Netscape, RSS 0.91 Userland, RSS 0.92, RSS 0.93, RSS 0.94, RSS 1.0, RSS 2.0, Atom 0.3, Atom 1.0. | | rome-modules| enables rome to handle several feed extensions like MediaRSS, GeoRSS and others. | From c0a3a2cd16e9cabb95533b40d3fc2173dbfe10fd Mon Sep 17 00:00:00 2001 From: mishako Date: Mon, 10 Oct 2016 22:16:53 +0200 Subject: [PATCH 2/6] Remove rome-utils from modules list in readme Utils module is not intended to be used on it's own. This is not the kind of information that should live in readme. --- README.md | 1 - 1 file changed, 1 deletion(-) diff --git a/README.md b/README.md index 4c11ab0..0ea3d48 100644 --- a/README.md +++ b/README.md @@ -7,7 +7,6 @@ ROME is a Java framework for RSS and Atom feeds. The framework consist of severa | Module | Description | | ------ | ----------- | -| rome-utils | provides utility classes that are used in several ROME modules. | | rome | is the main RSS and Atom library. It makes it easy to work with most syndication formats: RSS 0.90, RSS 0.91 Netscape, RSS 0.91 Userland, RSS 0.92, RSS 0.93, RSS 0.94, RSS 1.0, RSS 2.0, Atom 0.3, Atom 1.0. | | rome-modules| enables rome to handle several feed extensions like MediaRSS, GeoRSS and others. | | rome-opml | contains [OPML](https://en.wikipedia.org/wiki/OPML) parsers and tools. | From bc33fa68e8f047d4d508eaddae82c760a385abd5 Mon Sep 17 00:00:00 2001 From: mishako Date: Mon, 10 Oct 2016 22:20:11 +0200 Subject: [PATCH 3/6] List deprecated modules in readme No need for detailed description of modules that are deprecated and will be removed soon anyway. --- README.md | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 0ea3d48..5f785f4 100644 --- a/README.md +++ b/README.md @@ -10,10 +10,8 @@ ROME is a Java framework for RSS and Atom feeds. The framework consist of severa | rome | is the main RSS and Atom library. It makes it easy to work with most syndication formats: RSS 0.90, RSS 0.91 Netscape, RSS 0.91 Userland, RSS 0.92, RSS 0.93, RSS 0.94, RSS 1.0, RSS 2.0, Atom 0.3, Atom 1.0. | | rome-modules| enables rome to handle several feed extensions like MediaRSS, GeoRSS and others. | | rome-opml | contains [OPML](https://en.wikipedia.org/wiki/OPML) parsers and tools. | -| rome-fetcher | is a caching feed fetcher that supports retrieval of feeds via HTTP conditional GET. Supports ETags, GZip compression, and RFC3229 Delta encoding. | -| rome-certiorem | is a [PubSubHubub](https://en.wikipedia.org/wiki/PubSubHubbub) implementation based on rome. | -| rome-certiorem-webapp | is an example webapp for rome-certiorem | -| rome-propono | supports publishing protocols, specifically the Atom Publishing Protocol and the legacy MetaWeblog API. Propono includes an Atom client library, an Atom server framework and a Blog client that supports both Atom protocol and the MetaWeblog API. | + +Deprecated modules: `rome-fetcher`, `rome-certiorem`, `rome-certiorem-webapp` and `rome-propono`. ## Changelog From 13a5e407e58647c88cba3bd8e6088910630c16cf Mon Sep 17 00:00:00 2001 From: mishako Date: Mon, 10 Oct 2016 22:26:41 +0200 Subject: [PATCH 4/6] Simplify module descriptions in readme --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 5f785f4..266944d 100644 --- a/README.md +++ b/README.md @@ -7,9 +7,9 @@ ROME is a Java framework for RSS and Atom feeds. The framework consist of severa | Module | Description | | ------ | ----------- | -| rome | is the main RSS and Atom library. It makes it easy to work with most syndication formats: RSS 0.90, RSS 0.91 Netscape, RSS 0.91 Userland, RSS 0.92, RSS 0.93, RSS 0.94, RSS 1.0, RSS 2.0, Atom 0.3, Atom 1.0. | -| rome-modules| enables rome to handle several feed extensions like MediaRSS, GeoRSS and others. | -| rome-opml | contains [OPML](https://en.wikipedia.org/wiki/OPML) parsers and tools. | +| `rome` | Library for generating and parsing RSS and Atom feeds. | +| `rome-modules` | Generators and parsers for extensions like MediaRSS, GeoRSS and others. | +| `rome-opml` | [OPML](https://en.wikipedia.org/wiki/OPML) parsers and tools. | Deprecated modules: `rome-fetcher`, `rome-certiorem`, `rome-certiorem-webapp` and `rome-propono`. From 3f59e5c7eb2663a047329e961cef72aa19368255 Mon Sep 17 00:00:00 2001 From: mishako Date: Mon, 10 Oct 2016 22:30:33 +0200 Subject: [PATCH 5/6] Remove changelog from the readme The project is hosted on github. There is a UI for releases where we link to closed issues from each release. --- README.md | 28 ---------------------------- 1 file changed, 28 deletions(-) diff --git a/README.md b/README.md index 266944d..489a536 100644 --- a/README.md +++ b/README.md @@ -12,31 +12,3 @@ ROME is a Java framework for RSS and Atom feeds. The framework consist of severa | `rome-opml` | [OPML](https://en.wikipedia.org/wiki/OPML) parsers and tools. | Deprecated modules: `rome-fetcher`, `rome-certiorem`, `rome-certiorem-webapp` and `rome-propono`. - -## Changelog - -### 1.6.0 - -- [Upgrade of JDOM to version 2.0.5](https://github.com/rometools/rome/issues/197) -- [Maven plugin and dependency updates](https://github.com/rometools/rome/issues/268) -- [Support for allowing Doctype declarations in rome-fetcher](https://github.com/rometools/rome/issues/234) -- [OSGi improvements](https://github.com/rometools/rome/issues/143) - -### 1.5.1 - -- solved an [XML bomb](https://en.wikipedia.org/wiki/Billion_laughs) vulnerability - -Important note: due to the security fix ROME now forbids all Doctype declarations by default. This will break compatibility with RSS 0.91 Netscape -because it requires a Doctype declaration. When you experience problems you have to activate the property **allowDoctypes** on the SyndFeedInput object. You -should only use this possibility when the feeds that you process are absolutely trustful. - -### 1.5.0 - -- many (untracked) enhancements -- code cleanup -- renamed packages (was required to be able to push to Maven Central after years again) -- updated sourcecode to Java 1.6 - -### Prior to 1.5.0 - -- see [http://rometools.github.io/rome/ROMEReleases](http://rometools.github.io/rome/ROMEReleases) From cca2fb9a420faecbbfece396d365cf2751b91282 Mon Sep 17 00:00:00 2001 From: mishako Date: Mon, 10 Oct 2016 22:58:24 +0200 Subject: [PATCH 6/6] Add code examples to readme --- README.md | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/README.md b/README.md index 489a536..8afca64 100644 --- a/README.md +++ b/README.md @@ -12,3 +12,24 @@ ROME is a Java framework for RSS and Atom feeds. The framework consist of severa | `rome-opml` | [OPML](https://en.wikipedia.org/wiki/OPML) parsers and tools. | Deprecated modules: `rome-fetcher`, `rome-certiorem`, `rome-certiorem-webapp` and `rome-propono`. + +## Examples + +Parse a feed: + +```java +String url = "http://stackoverflow.com/feeds/tag?tagnames=rome"; +SyndFeed feed = new SyndFeedInput().build(new XmlReader(new URL(url))); +System.out.println(feed.getTitle()); +``` + +Generate a feed: + +```java +SyndFeed feed = new SyndFeedImpl(); +feed.setFeedType("rss_2.0"); +feed.setTitle("test-title"); +feed.setDescription("test-description"); +feed.setLink("https://example.org"); +System.out.println(new SyndFeedOutput().outputString(feed)); +```