Kieker 1.9

kieker.tools.traceAnalysis.filter.visualization
Class GraphWriterPlugin

java.lang.Object
  extended by kieker.analysis.analysisComponent.AbstractAnalysisComponent
      extended by kieker.analysis.plugin.AbstractPlugin
          extended by kieker.analysis.plugin.filter.AbstractFilterPlugin
              extended by kieker.tools.traceAnalysis.filter.visualization.GraphWriterPlugin
All Implemented Interfaces:
IAnalysisComponent, IFilterPlugin, IPlugin

public class GraphWriterPlugin
extends AbstractFilterPlugin

Generic graph writer plugin to generate graph specifications and save them to disk. This plugin uses a formatter registry (see FORMATTER_REGISTRY) to determine the appropriate formatter for a given graph.

Since:
1.6
Author:
Holger Knoche

Nested Class Summary
 
Nested classes/interfaces inherited from interface kieker.analysis.plugin.IPlugin
IPlugin.PluginInputPortReference, IPlugin.STATE
 
Field Summary
static String CONFIG_PROPERTY_NAME_INCLUDE_WEIGHTS
          Name of the configuration property indicating that weights should be included.
static String CONFIG_PROPERTY_NAME_OUTPUT_FILE_NAME
          Name of the configuration property containing the output file name.
static String CONFIG_PROPERTY_NAME_OUTPUT_PATH_NAME
          Name of the configuration property containing the output path name.
static String CONFIG_PROPERTY_NAME_SELFLOOPS
          Name of the configuration property indicating that self-loops should be displayed.
static String CONFIG_PROPERTY_NAME_SHORTLABELS
          Name of the configuration property indicating that short labels should be used.
static String INPUT_PORT_NAME_GRAPHS
          Name of the plugin's graph input port.
 
Fields inherited from class kieker.analysis.analysisComponent.AbstractAnalysisComponent
CONFIG_NAME
 
Constructor Summary
GraphWriterPlugin(Configuration configuration, IProjectContext projectContext)
          Creates a new instance of this class using the given parameters.
 
Method Summary
 Configuration getCurrentConfiguration()
          This method should deliver a Configuration object containing the current configuration of this instance. In other words: The constructor should be able to use the given object to initialize a new instance of this class with the same intern properties.
 void writeGraph(AbstractGraph<?,?,?> graph)
          Formats a given graph and saves the generated specification to disk.
 
Methods inherited from class kieker.analysis.plugin.filter.AbstractFilterPlugin
init, terminate
 
Methods inherited from class kieker.analysis.plugin.AbstractPlugin
areAllRepositoryPortsConnected, connect, connect, getAllDisplayNames, getAllInputPortNames, getAllOutputPortNames, getAllRepositoryPortNames, getConnectedPlugins, getCurrentRepositories, getIncomingPlugins, getPluginDescription, getPluginName, getState, isConnectionAllowed, shutdown, start
 
Methods inherited from class kieker.analysis.analysisComponent.AbstractAnalysisComponent
getName
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface kieker.analysis.plugin.IPlugin
connect, getAllDisplayNames, getAllInputPortNames, getAllOutputPortNames, getAllRepositoryPortNames, getConnectedPlugins, getCurrentRepositories, getName, getPluginDescription, getPluginName, getState
 

Field Detail

CONFIG_PROPERTY_NAME_OUTPUT_FILE_NAME

public static final String CONFIG_PROPERTY_NAME_OUTPUT_FILE_NAME
Name of the configuration property containing the output file name.

See Also:
Constant Field Values

CONFIG_PROPERTY_NAME_OUTPUT_PATH_NAME

public static final String CONFIG_PROPERTY_NAME_OUTPUT_PATH_NAME
Name of the configuration property containing the output path name.

See Also:
Constant Field Values

CONFIG_PROPERTY_NAME_INCLUDE_WEIGHTS

public static final String CONFIG_PROPERTY_NAME_INCLUDE_WEIGHTS
Name of the configuration property indicating that weights should be included.

See Also:
Constant Field Values

CONFIG_PROPERTY_NAME_SHORTLABELS

public static final String CONFIG_PROPERTY_NAME_SHORTLABELS
Name of the configuration property indicating that short labels should be used.

See Also:
Constant Field Values

CONFIG_PROPERTY_NAME_SELFLOOPS

public static final String CONFIG_PROPERTY_NAME_SELFLOOPS
Name of the configuration property indicating that self-loops should be displayed.

See Also:
Constant Field Values

INPUT_PORT_NAME_GRAPHS

public static final String INPUT_PORT_NAME_GRAPHS
Name of the plugin's graph input port.

See Also:
Constant Field Values
Constructor Detail

GraphWriterPlugin

public GraphWriterPlugin(Configuration configuration,
                         IProjectContext projectContext)
Creates a new instance of this class using the given parameters.

Parameters:
configuration - The configuration for this component.
projectContext - The project context for this component.
Method Detail

getCurrentConfiguration

public Configuration getCurrentConfiguration()
This method should deliver a Configuration object containing the current configuration of this instance. In other words: The constructor should be able to use the given object to initialize a new instance of this class with the same intern properties.

Specified by:
getCurrentConfiguration in interface IAnalysisComponent
Specified by:
getCurrentConfiguration in interface IPlugin
Specified by:
getCurrentConfiguration in class AbstractAnalysisComponent
Returns:
A completely filled configuration object.

writeGraph

public void writeGraph(AbstractGraph<?,?,?> graph)
Formats a given graph and saves the generated specification to disk. The file name to save the output to is specified by a the configuration options CONFIG_PROPERTY_NAME_OUTPUT_PATH_NAME and CONFIG_PROPERTY_NAME_OUTPUT_FILE_NAME.

Parameters:
graph - The graph to save

Kieker 1.9

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