Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

The Problem RSS (Really Simple Syndication) is an XML application for distributing web content that changes frequently. Many news-related sites, weblogs and other online publishers

image text in transcribed
image text in transcribed
The Problem RSS (Really Simple Syndication) is an XML application for distributing web content that changes frequently. Many news-related sites, weblogs and other online publishers syndicate their content as an RSS Feed to whoever wants it. For this project your task is to write a program that asks the user for the URL of an RSS 2.0 feed and for the name of an output file including the html extension, reads the RSS feed into an xMLTree object and then uses the information in the xoLrree object to generate in the output file a nicely formatted HTML page with table of links to all the news items in the original feed. Input: RSS 2.0 XML Document Here is a simplified deseription of the structure of an RSS 2.0 XML document. RSS 2.0 documents can contain a few other tags and features, but these are the ones you will need for the project. Note the following properties of RSS 2.0 XML documents: - The children of the eehannels tag and of the title>, , and > are required children of the cehannel> tag, i.e., you should assume they are present. However, and cdeser iption> may be blank, i.e., they may not have any text child. - All the children of tag are optional, i.e., do not assume they are present; but, either or must be present. However, the and/or tags, even if present, may be blank, i.e, they may not have any text child. - If a tag appears as a child of an tag, it must have a ur1 attribute. Note that when your program creates an xMLTree object from a given RSS 2.0 feed, if it is successful, all you know is that the input is a valid XML document. It is up to your program to check that the label of the root of the XMLTree is an tag and that it has a version attribute with value " 2.0. After that, your program can assume that the input is indeed a valid RSS 2.0 feed and the xMLTree has the structure described above; in other words, you do not need to check for the existence of the tag, or the , , and tags inside that. Make sure you do not make any assumptions that are not. specified in the structure described above and, in particular, make sure to check that the channel's and tags and each item's and tags have a child before trying to access it. However, the 's children and , if present, are required to have a child with the needed information. (See slide \#9 in RSS for a diagram capturing these requirements.) Output: HTML Web Page These are the minimum requirements for the generated web page. If you think you can produce better output or include more information, you should consult your instructor to make sure that any changes you want to implement are acceptable. This is what your output should include: - the title as the page title (or "Empty Title" if the tag has no children) - a header with the page title inside a link to the link - a paragraph with the tag has no children) - a table with appropriate headers; each row should correspond to one news item with the following columns: - the publication date, if present, or "No date available" - the source, if present, which should be linked to the source url, or "No source available" - the title, if present and not empty, or the description, if not empty, or "No title available", which should be linked if a link for the news item is available You can see an example of the output here (note that the links may be outdated and no longer available). Method 1. Create a new Eclipse project by copying projectTemplate and name the new project RSSReader. 2. Open the sre folder of this project and then open (default package). As a starting point you can use any of the Java files. Rename it RSSReader and delete the other files from the project. Open the RssReader. java file in the editor. 3. Follow the link to RSsReader. Jaxa, select all the code on that page, copy it to the clipboard, and paste it into Eclipse's editor window to replace the skeleton code. 4. Edit rsseeader. java to satisfy the problem requirements stated above by completing the methods provided

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Oracle Database 10g Insider Solutions

Authors: Arun R. Kumar, John Kanagaraj, Richard Stroupe

1st Edition

0672327910, 978-0672327919

More Books

Students also viewed these Databases questions

Question

Describe the linkages between HRM and strategy formulation. page 74

Answered: 1 week ago

Question

Identify approaches to improving retention rates.

Answered: 1 week ago