Kieker 1.12

kieker.monitoring.core.controller
Class SamplingController

java.lang.Object
  extended by kieker.monitoring.core.controller.AbstractController
      extended by kieker.monitoring.core.controller.SamplingController
All Implemented Interfaces:
ISamplingController

public final class SamplingController
extends AbstractController
implements ISamplingController

Since:
1.3
Author:
Andre van Hoorn, Jan Waller

Field Summary
 
Fields inherited from class kieker.monitoring.core.controller.AbstractController
monitoringController
 
Constructor Summary
protected SamplingController(Configuration configuration)
          Creates a new instance of this class using the given configuration to initialize the class.
 
Method Summary
protected  void cleanup()
          This method should clean up.
protected  void init()
          This method should to the initialization work.
 boolean removeScheduledSampler(ScheduledSamplerJob sensorJob)
          Stops future executions of the given periodic ScheduledSamplerJob .
 ScheduledSamplerJob schedulePeriodicSampler(ISampler sensor, long initialDelay, long period, java.util.concurrent.TimeUnit timeUnit)
          Schedules the given ISampler with given initial delay, and period.
 java.lang.String toString()
           
 
Methods inherited from class kieker.monitoring.core.controller.AbstractController
createAndInitialize, isTerminated, setMonitoringController, terminate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SamplingController

protected SamplingController(Configuration configuration)
Creates a new instance of this class using the given configuration to initialize the class.

Parameters:
configuration - The configuration used to initialize this controller.
Method Detail

init

protected final void init()
Description copied from class: AbstractController
This method should to the initialization work.

Specified by:
init in class AbstractController

cleanup

protected final void cleanup()
Description copied from class: AbstractController
This method should clean up.

Specified by:
cleanup in class AbstractController

toString

public final java.lang.String toString()
Specified by:
toString in class AbstractController

schedulePeriodicSampler

public final ScheduledSamplerJob schedulePeriodicSampler(ISampler sensor,
                                                         long initialDelay,
                                                         long period,
                                                         java.util.concurrent.TimeUnit timeUnit)
Schedules the given ISampler with given initial delay, and period.

Specified by:
schedulePeriodicSampler in interface ISamplingController
Parameters:
sensor - The sampler to schedule.
initialDelay - The initial delay.
period - The period.
timeUnit - The time unit which determines how to interpret the given parameter.
Returns:
a ScheduledSamplerJob as a handler for removing the scheduled sampler later on by using the method ISamplingController.removeScheduledSampler(ScheduledSamplerJob).

removeScheduledSampler

public final boolean removeScheduledSampler(ScheduledSamplerJob sensorJob)
Stops future executions of the given periodic ScheduledSamplerJob .

Specified by:
removeScheduledSampler in interface ISamplingController
Parameters:
sensorJob - The sampler to be removed.
Returns:
true if the sensor is not registered

Kieker 1.12

Copyright 2015 Kieker Project, http://kieker-monitoring.net