|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object yarfraw.io.FeedWriter
public class FeedWriter
Provides a set of function to facilitate writing to a feed.
*Note* This class is not thread safe.
Field Summary | |
---|---|
protected File |
_file
|
protected FeedFormat |
_format
|
Constructor Summary | |
---|---|
FeedWriter(File file)
|
|
FeedWriter(File file,
FeedFormat format)
|
|
FeedWriter(String pathName)
|
|
FeedWriter(String pathName,
FeedFormat format)
|
|
FeedWriter(URI uri)
|
|
FeedWriter(URI uri,
FeedFormat format)
|
Method Summary | |
---|---|
File |
getFile()
|
FeedFormat |
getFormat()
The FeedFormat this writer should be using.if this is not set, the default is RSS 2.0 format. |
void |
setFile(File file)
|
void |
setFormat(FeedFormat format)
The FeedFormat this writer should be using.if this is not set, the default is RSS 2.0 format. |
void |
writeChannel(ChannelFeed channel)
Writes a channel to the feed file with a custom ValidationEventHandler |
void |
writeChannel(ChannelFeed channel,
ValidationEventHandler validationEventHandler)
Writes a channel to the feed file with a custom ValidationEventHandler . |
static void |
writeChannel(FeedFormat format,
ChannelFeed channel,
OutputStream outputStream)
Writes a channel to the feed file with a custom ValidationEventHandler . |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected File _file
protected FeedFormat _format
Constructor Detail |
---|
public FeedWriter(File file, FeedFormat format)
public FeedWriter(String pathName, FeedFormat format)
public FeedWriter(URI uri, FeedFormat format)
public FeedWriter(File file)
public FeedWriter(String pathName)
public FeedWriter(URI uri)
Method Detail |
---|
public void writeChannel(ChannelFeed channel) throws YarfrawException
ValidationEventHandler
channel
- a valid ChannelFeed
YarfrawException
- if write operation failed.public static void writeChannel(FeedFormat format, ChannelFeed channel, OutputStream outputStream) throws YarfrawException
ValidationEventHandler
.
format
- any valid FeedFormat
channel
- a valid ChannelFeed
outputStream
- an OutputStream
YarfrawException
- if write operation failed.public void writeChannel(ChannelFeed channel, ValidationEventHandler validationEventHandler) throws YarfrawException
ValidationEventHandler
.
channel
- a valid ChannelFeed
validationEventHandler
- a custom ValidationEventHandler
YarfrawException
- if write operation failed.public File getFile()
public void setFile(File file)
public FeedFormat getFormat()
FeedFormat
this writer should be using.null
format is ignored
rss 2.0 is recommended, use other format if you really need to
public void setFormat(FeedFormat format)
FeedFormat
this writer should be using.null
format is ignored
rss 2.0 is recommended, use other format if you really need to
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |