I'm working on a project that read RSS feed using java, I use this tutorial they using Stax parser.My question is how I can read attributes values ?
http://www.vogella.com/tutorials/RSSFeed/article.html
This is the RSSReader class,
package de.vogella.rss.read;
import java.io.IOException;
import java.io.InputStream;
import java.net.MalformedURLException;
import java.net.URL;
import javax.xml.stream.XMLEventReader;
import javax.xml.stream.XMLInputFactory;
import javax.xml.stream.XMLStreamException;
import javax.xml.stream.events.Characters;
import javax.xml.stream.events.XMLEvent;
import de.vogella.rss.model.Feed;
import de.vogella.rss.model.FeedMessage;
public class RSSFeedParser {
static final String TITLE = "title";
static final String DESCRIPTION = "description";
static final String CHANNEL = "channel"; …Run Code Online (Sandbox Code Playgroud)