|
Dekoh platform API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectdekoh.portal.syndication.aggregator.core.AggregatorImpl
public class AggregatorImpl
AggregatorImpl is the default feed aggregator implementation provided. Instances of this can be created
by AggregatorFactory . All instances of this class will share a single timer thread. Aggregator timer task
will be non blocking and will return once it has submited the aggragation job to an executor pool.
| Field Summary | |
|---|---|
protected File |
cacheDir
|
protected FeedRetriever |
feedRetriever
|
| Method Summary | |
|---|---|
void |
addAggregatedItemTransformer(AggregatedItemTransformer[] transformers)
|
void |
destroy()
Stops the scheduler. |
List |
getAggregatedItemTransformers()
|
File |
getAggregatedRSSFeedXml()
After aggregation the aggregated feed is stored in a file named "aggregate-subscriptionListId.xml", if it is an inMemorySubscriptionList, aggregated file will be stored as "aggregate-aggregatorId.xml" |
FeedRetriever |
getFeedRetriever()
|
String |
getId()
|
File |
getItemRSSFeedXml(String subscriptionItemId)
Each downloaded subscription item feed is stored in a file named "aggregate-subscriptionListId-subscriptionItemId.xml" |
long |
getLastAggregatedTime()
|
long |
getLastModifiedTime()
|
int |
getMaxItemsToAggregate()
|
long |
getSchedulerFrequency()
|
SubscriptionItemFetcher |
getSubscriptionItemFetcher()
|
SubscriptionList |
getSubscriptionList()
|
boolean |
isScheduled()
|
void |
scheduleAggregation()
Triggers a periodic aggregation that becomes enabled now, and subsequently repeats itself after a frequency.Implementatin can chose to have a defualt frequency or take in the the constructor Generally this will be a one time call, However it can be used to start aggregation "now", to check for latest feeds |
void |
scheduleAggregation(long frequencyInMilliSec)
It will stop the aggregation if it is running and reschedule the aggregation with the specified frequecy |
void |
setMaxItemsToAggregate(int maxItemsToAggregate)
|
void |
stopScheduler()
Stops the scheduling of aggregator. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected FeedRetriever feedRetriever
protected File cacheDir
| Method Detail |
|---|
public SubscriptionItemFetcher getSubscriptionItemFetcher()
public FeedRetriever getFeedRetriever()
public final String getId()
getId in interface Aggregatorpublic List getAggregatedItemTransformers()
getAggregatedItemTransformers in interface Aggregatorpublic int getMaxItemsToAggregate()
getMaxItemsToAggregate in interface Aggregatorpublic SubscriptionList getSubscriptionList()
getSubscriptionList in interface Aggregatorpublic long getLastAggregatedTime()
getLastAggregatedTime in interface Aggregatorpublic long getLastModifiedTime()
getLastModifiedTime in interface Aggregatorpublic void setMaxItemsToAggregate(int maxItemsToAggregate)
setMaxItemsToAggregate in interface AggregatormaxItemsToAggregate - maximum items that will be aggregated byu this aggregater. Aggregators may choose a
policy to remove items from the aggregated feed if the total no of aggregated items
exceeds this limit.public File getAggregatedRSSFeedXml()
getAggregatedRSSFeedXml in interface Aggregatorpublic void scheduleAggregation()
Aggregator
scheduleAggregation in interface AggregatorAggregator.scheduleAggregation(long)public void scheduleAggregation(long frequencyInMilliSec)
scheduleAggregation in interface AggregatorfrequencyInMilliSec - frequency with which aggregation will happenpublic void stopScheduler()
Aggregator
stopScheduler in interface AggregatorAggregator.scheduleAggregation(long)public boolean isScheduled()
isScheduled in interface Aggregatorscheduled stopped public long getSchedulerFrequency()
getSchedulerFrequency in interface Aggregatorpublic void destroy()
InMemorySubscriptionList deletes all the downloaded feeds
files and the aggregated file created during the aggregation process
destroy in interface Aggregatorpublic void addAggregatedItemTransformer(AggregatedItemTransformer[] transformers)
addAggregatedItemTransformer in interface Aggregatortransformers - which will be given a callback before a new feed entry is made part of aggregated itempublic File getItemRSSFeedXml(String subscriptionItemId)
getItemRSSFeedXml in interface AggregatorsubscriptionItemId - id of a subscription item in the list
|
Dekoh platform API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
© 2009 Pramati Technologies - Dekoh - Portal for Developers