Kieker 1.12

kieker.monitoring.writer
Class AbstractMonitoringWriter

java.lang.Object
  extended by kieker.monitoring.writer.AbstractMonitoringWriter
All Implemented Interfaces:
IMonitoringRecordReceiver, IMonitoringWriter
Direct Known Subclasses:
AbstractAsyncWriter, DummyWriter, JMXWriter, PipeWriter, PrintStreamWriter, SyncDbWriter, SyncFsWriter

public abstract class AbstractMonitoringWriter
extends java.lang.Object
implements IMonitoringWriter

Since:
1.3
Author:
Jan Waller, Robert von Massow

Field Summary
protected  IMonitoringController monitoringController
          The controller of this writer.
 
Constructor Summary
protected AbstractMonitoringWriter(Configuration configuration)
           
 
Method Summary
protected  Configuration getDefaultConfiguration()
          This method should be overwritten, iff the writer is external to Kieker and thus its default configuration is not included in the default config file.
protected abstract  void init()
          Implementing classes should indicate an initialization error by throwing an Exception.
 boolean newMonitoringRecordNonBlocking(IMonitoringRecord record)
          Overwrite this method if necessary.
 void setController(IMonitoringController controller)
          Set the IMonitoringController controlling this writer.
 java.lang.String toString()
          Delivers a string representation of this writer.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface kieker.monitoring.writer.IMonitoringWriter
newMonitoringRecord, terminate
 

Field Detail

monitoringController

protected IMonitoringController monitoringController
The controller of this writer.

Constructor Detail

AbstractMonitoringWriter

protected AbstractMonitoringWriter(Configuration configuration)
Parameters:
configuration - The configuration for this component.
Method Detail

getDefaultConfiguration

protected Configuration getDefaultConfiguration()
This method should be overwritten, iff the writer is external to Kieker and thus its default configuration is not included in the default config file.

Returns:
The configuration object containing the default configuration.

toString

public java.lang.String toString()
Description copied from interface: IMonitoringWriter
Delivers a string representation of this writer.

Specified by:
toString in interface IMonitoringWriter
Overrides:
toString in class java.lang.Object
Returns:
A string.

setController

public final void setController(IMonitoringController controller)
                         throws java.lang.Exception
Description copied from interface: IMonitoringWriter
Set the IMonitoringController controlling this writer.

Specified by:
setController in interface IMonitoringWriter
Parameters:
controller - The monitoring controller which will be the new parent of this writer.
Throws:
java.lang.Exception - If something went wrong.

init

protected abstract void init()
                      throws java.lang.Exception
Implementing classes should indicate an initialization error by throwing an Exception.

Throws:
java.lang.Exception - If something during the initialization went wrong.

newMonitoringRecordNonBlocking

public boolean newMonitoringRecordNonBlocking(IMonitoringRecord record)
Overwrite this method if necessary.

Specified by:
newMonitoringRecordNonBlocking in interface IMonitoringWriter
Parameters:
record - the record.
Returns:
true on success; false in case of an error.

Kieker 1.12

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