net.sf.infrared.agent.transport
Class LocalCollectionStrategy

java.lang.Object
  extended bynet.sf.infrared.agent.transport.LocalCollectionStrategy
All Implemented Interfaces:
CollectionStrategy

public class LocalCollectionStrategy
extends Object
implements CollectionStrategy

This CollectionStrategy impelementation is used in case the infrared web application is not a remote application. This merges the statistics object with the global statistics object


Constructor Summary
LocalCollectionStrategy()
           
 
Method Summary
 boolean collect(Statistics stats)
          Needs to hanle the collection of statistic objects.
 boolean destroy()
          Destroy the strategy, bring the flush policy etc down.
 boolean init(MonitorConfig configuration)
          Initialize the collection strategy, this methods need to be overridden to create the aggregator, forwarder & the flush policy and tie them together
 void resume()
          Resume statistics collection
 void suspend()
          Suspend statistics collection
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LocalCollectionStrategy

public LocalCollectionStrategy()
Method Detail

init

public boolean init(MonitorConfig configuration)
Description copied from interface: CollectionStrategy
Initialize the collection strategy, this methods need to be overridden to create the aggregator, forwarder & the flush policy and tie them together

Specified by:
init in interface CollectionStrategy
Returns:

collect

public boolean collect(Statistics stats)
Description copied from interface: CollectionStrategy
Needs to hanle the collection of statistic objects. This method will be called after the execution of a request is complete

Specified by:
collect in interface CollectionStrategy
Parameters:
stats - - statistics object that needs to be
Returns:
true if the operation succeded other wise false

suspend

public void suspend()
Description copied from interface: CollectionStrategy
Suspend statistics collection

Specified by:
suspend in interface CollectionStrategy

resume

public void resume()
Description copied from interface: CollectionStrategy
Resume statistics collection

Specified by:
resume in interface CollectionStrategy

destroy

public boolean destroy()
Description copied from interface: CollectionStrategy
Destroy the strategy, bring the flush policy etc down.

Specified by:
destroy in interface CollectionStrategy
Returns: