Overview     Modules     Class Hierarchy     Classes     Members  

tlp::PropertyAlgorithm Class Reference
[Plugins]

This base class describes plug-ins who only modify one property, e.g. selection. More...

#include <PropertyAlgorithm.h>

Inheritance diagram for tlp::PropertyAlgorithm:
Collaboration diagram for tlp::PropertyAlgorithm:

List of all members.

Public Member Functions

Public Attributes


Detailed Description

This base class describes plug-ins who only modify one property, e.g. selection.


Constructor & Destructor Documentation

tlp::PropertyAlgorithm::PropertyAlgorithm ( const tlp::PropertyContext context  )  [inline]

Builds a new plug-in that modifies a single property.

Parameters:
context The context containing the Graph and PropertyInterface this plug-in has access to,a s well as a PluginProgress.
virtual tlp::PropertyAlgorithm::~PropertyAlgorithm (  )  [inline, virtual]

Member Function Documentation

virtual bool tlp::PropertyAlgorithm::check ( std::string &  errorMessage  )  [inline, virtual]

Checks whether the algorithm can ru on this Graph or not. If not, the reason why should be reported through the PluginProgress.

Parameters:
errorMessage A string whose value will be modified to an error message, if the check fails.
Returns:
bool Whether the plug-in can run on this Graph.
bool tlp::PropertyAlgorithm::preservePropertyUpdates ( PropertyInterface prop  )  [inline]
virtual bool tlp::PropertyAlgorithm::run (  )  [inline, virtual]

Runs the algorithm. It is a good practice to report progress through the PluginProgress, Even if your algorithm is very fast. Keep in mind that Tulip can handle very large graphs. The PluginProgress should also be used to report errors, if any.

Returns:
bool Whether the algorithm execution was sucessfull or not.

Member Data Documentation



Tulip Software by LaBRI Visualization Team    2001 - 2011