Kieker 1.12

kieker.tools.traceAnalysis.filter.visualization.callTree
Class AbstractCallTreeFilter<T>

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.AbstractTraceAnalysisFilter
                  extended by kieker.tools.traceAnalysis.filter.AbstractTraceProcessingFilter
                      extended by kieker.tools.traceAnalysis.filter.AbstractMessageTraceProcessingFilter
                          extended by kieker.tools.traceAnalysis.filter.visualization.callTree.AbstractCallTreeFilter<T>
Type Parameters:
T -
All Implemented Interfaces:
IAnalysisComponent, IFilterPlugin, IPlugin
Direct Known Subclasses:
AbstractAggregatedCallTreeFilter

public abstract class AbstractCallTreeFilter<T>
extends AbstractMessageTraceProcessingFilter

Plugin providing the creation of calling trees both for individual traces and an aggregated form multiple traces.

Since:
1.1
Author:
Andre van Hoorn

Nested Class Summary
static interface AbstractCallTreeFilter.IPairFactory<T>
           
 
Nested classes/interfaces inherited from interface kieker.analysis.plugin.IPlugin
IPlugin.PluginInputPortReference, IPlugin.STATE
 
Field Summary
 
Fields inherited from class kieker.tools.traceAnalysis.filter.AbstractMessageTraceProcessingFilter
INPUT_PORT_NAME_MESSAGE_TRACES
 
Fields inherited from class kieker.tools.traceAnalysis.filter.AbstractTraceAnalysisFilter
CONFIG_PROPERTY_VALUE_VERBOSE, LOG, REPOSITORY_PORT_NAME_SYSTEM_MODEL
 
Fields inherited from class kieker.analysis.analysisComponent.AbstractAnalysisComponent
CONFIG_NAME, configuration, log, projectContext, recordsTimeUnitFromProjectContext
 
Constructor Summary
AbstractCallTreeFilter(Configuration configuration, IProjectContext projectContext)
          Creates a new instance of this class using the given parameters.
 
Method Summary
protected static
<T> void
addTraceToTree(AbstractCallTreeNode<T> root, MessageTrace t, AbstractCallTreeFilter.IPairFactory<T> pairFactory, boolean aggregated)
          Adds the given trace to the given tree.
protected static java.lang.String nodeLabel(AbstractCallTreeNode<?> node, boolean shortLabels)
           
protected static void saveTreeToDotFile(AbstractCallTreeNode<?> root, java.lang.String outputFn, boolean includeWeights, boolean includeEois, boolean shortLabels)
          This method saves the given tree as valid dot code into the given file.
static
<T> void
writeDotForMessageTrace(AbstractCallTreeNode<T> root, AbstractCallTreeFilter.IPairFactory<T> pairFactory, MessageTrace msgTrace, java.lang.String outputFilename, boolean includeWeights, boolean shortLabels)
           
 
Methods inherited from class kieker.tools.traceAnalysis.filter.AbstractMessageTraceProcessingFilter
inputMessageTraces
 
Methods inherited from class kieker.tools.traceAnalysis.filter.AbstractTraceProcessingFilter
getErrorCount, getLastTraceIdError, getLastTraceIdSuccess, getSuccessCount, getTotalCount, printStatusMessage, reportError, reportSuccess
 
Methods inherited from class kieker.tools.traceAnalysis.filter.AbstractTraceAnalysisFilter
createExecutionByEntityNames, createExecutionByEntityNames, createExecutionByEntityNames, createExecutionByEntityNames, getCurrentConfiguration, getSystemEntityFactory, printDebugLogMessage, printErrorLogMessage
 
Methods inherited from class kieker.analysis.plugin.filter.AbstractFilterPlugin
init, terminate
 
Methods inherited from class kieker.analysis.plugin.AbstractPlugin
areAllRepositoryPortsConnected, connect, connect, deliver, getAllDisplayNames, getAllInputPortNames, getAllOutputPortNames, getAllRepositoryPortNames, getConnectedPlugins, getCurrentRepositories, getDefaultConfiguration, getIncomingPlugins, getPluginDescription, getPluginName, getRepository, getState, isConnectionAllowed, notifyNewIncomingConnection, notifyNewOutgoingConnection, shutdown, start
 
Methods inherited from class kieker.analysis.analysisComponent.AbstractAnalysisComponent
getName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, 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
 

Constructor Detail

AbstractCallTreeFilter

public AbstractCallTreeFilter(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

nodeLabel

protected static final java.lang.String nodeLabel(AbstractCallTreeNode<?> node,
                                                  boolean shortLabels)

saveTreeToDotFile

protected static void saveTreeToDotFile(AbstractCallTreeNode<?> root,
                                        java.lang.String outputFn,
                                        boolean includeWeights,
                                        boolean includeEois,
                                        boolean shortLabels)
                                 throws java.io.FileNotFoundException,
                                        java.io.UnsupportedEncodingException
This method saves the given tree as valid dot code into the given file.

Parameters:
root - The root of the tree.
outputFn - The file in which the code will be written.
includeWeights - Determines whether to include weights or not.
includeEois - Determines whether to include the execution order indices or not.
shortLabels - Determines whether to use short labels or not.
Throws:
java.io.FileNotFoundException - If the given file is somehow invalid.
java.io.UnsupportedEncodingException - If the default encoding is not supported.

addTraceToTree

protected static <T> void addTraceToTree(AbstractCallTreeNode<T> root,
                                         MessageTrace t,
                                         AbstractCallTreeFilter.IPairFactory<T> pairFactory,
                                         boolean aggregated)
                              throws TraceProcessingException
Adds the given trace to the given tree.

Type Parameters:
T - The type of the tree.
Parameters:
root - The root of the call tree.
t - The trace to add.
pairFactory - The factory creating the necessary pairs for the tree.
aggregated - Determines whether the tree is aggregated or not.
Throws:
TraceProcessingException - If the message type is not supported or the trace is somehow invalid.

writeDotForMessageTrace

public static <T> void writeDotForMessageTrace(AbstractCallTreeNode<T> root,
                                               AbstractCallTreeFilter.IPairFactory<T> pairFactory,
                                               MessageTrace msgTrace,
                                               java.lang.String outputFilename,
                                               boolean includeWeights,
                                               boolean shortLabels)
                                    throws java.io.FileNotFoundException,
                                           TraceProcessingException,
                                           java.io.UnsupportedEncodingException
Throws:
java.io.FileNotFoundException
TraceProcessingException
java.io.UnsupportedEncodingException

Kieker 1.12

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