|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.clapper.curn.plugins.ParsedFeedURLEditPlugIn
public class ParsedFeedURLEditPlugIn
The ParsedFeedURLEditPlugIn edits a feed after it has been parsed, adjusting the URLs in the feed (i.e., the item URLs and the channel, or feed, URL) according to various configuration parameters. It can be used to fix known errors in the XML. It intercepts the following per-feed configuration parameters:
| EditItemURLsuffix | Specifies a regular expression to be applied to the URLs for all items in the feed. Multiple expressions may be specified per feed. See the User's Guide for details. |
| EditFeedURLsuffix | Specifies a regular expression to be applied to the channel, or feed, URL. Multiple expressions may be specified per feed. See the User's Guide for details. |
| PruneURLs | Specifies that all URLs should be pruned of their HTTP parameters. This action also can be accomplished with edit directives, using the above configuration items; this parameter is a convenience. |
| Constructor Summary | |
|---|---|
ParsedFeedURLEditPlugIn()
Default constructor (required). |
|
| Method Summary | |
|---|---|
java.lang.String |
getPlugInName()
Get a displayable name for the plug-in. |
java.lang.String |
getPlugInSortKey()
Get the sort key for this plug-in. |
void |
initPlugIn()
Initialize the plug-in. |
boolean |
runFeedConfigItemPlugIn(java.lang.String sectionName,
java.lang.String paramName,
CurnConfig config,
FeedInfo feedInfo)
Called immediately after curn has read and processed a configuration item in a "feed" configuration section. |
boolean |
runPostFeedParsePlugIn(FeedInfo feedInfo,
RSSChannel channel)
Called immediately after a feed is parsed, but before it is otherwise processed. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ParsedFeedURLEditPlugIn()
| Method Detail |
|---|
public java.lang.String getPlugInName()
getPlugInName in interface PlugInpublic java.lang.String getPlugInSortKey()
getPlugInSortKey in interface PlugIn
public void initPlugIn()
throws CurnException
initPlugIn in interface PlugInCurnException - on error
public boolean runFeedConfigItemPlugIn(java.lang.String sectionName,
java.lang.String paramName,
CurnConfig config,
FeedInfo feedInfo)
throws CurnException
runFeedConfigItemPlugIn in interface FeedConfigItemPlugInsectionName - the name of the configuration section where
the item was foundparamName - the name of the parameterconfig - the active configurationfeedInfo - partially complete FeedInfo object
for the feed. The URL is guaranteed to be
present, but no other fields are.
CurnException - on errorCurnConfig,
FeedInfo,
FeedInfo.getURL()
public boolean runPostFeedParsePlugIn(FeedInfo feedInfo,
RSSChannel channel)
throws CurnException
runPostFeedParsePlugIn in interface PostFeedParsePlugInfeedInfo - the FeedInfo object for the feed that
has been downloaded and parsed.channel - the parsed channel data
CurnException - on errorRSSChannel,
FeedInfo
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||