Tulip  4.1.0
Better Visualization Through Research
 All Classes Files Functions Variables Enumerations Enumerator Properties Groups Pages
tlp::Plugin Class Referenceabstract

#include <Plugin.h>

Inherits tlp::WithParameter, and tlp::WithDependency.

Inherited by tlp::Algorithm, tlp::Interactor, tlp::Perspective, and tlp::View.

Public Member Functions

virtual std::string author () const =0
 
virtual std::string category () const =0
 
virtual std::string date () const =0
 
virtual std::string group () const =0
 
virtual std::string icon () const
 
virtual int id () const
 
virtual std::string info () const =0
 
virtual std::string major () const
 
virtual std::string minor () const
 
virtual std::string name () const =0
 
virtual std::string release () const =0
 
virtual std::string tulipMajor () const
 
virtual std::string tulipMinor () const
 
virtual std::string tulipRelease () const =0
 
- Public Member Functions inherited from tlp::WithParameter
template<typename T >
void addInOutParameter (const std::string &name, const std::string &help=std::string(), const std::string &defaultValue=std::string(), bool isMandatory=true)
 
template<typename T >
void addInParameter (const std::string &name, const std::string &help, const std::string &defaultValue, bool isMandatory=true)
 
template<typename T >
void addOutParameter (const std::string &name, const std::string &help=std::string(), const std::string &defaultValue=std::string(), bool isMandatory=true)
 
template<typename T >
void addParameter (const std::string &name, const std::string &help=std::string(), const std::string &defaultValue=std::string(), bool isMandatory=true)
 
const
tlp::ParameterDescriptionList
getParameters () const
 
- Public Member Functions inherited from tlp::WithDependency
void addDependency (const char *name, const char *release)
 
const std::list< Dependency > & dependencies () const
 

Additional Inherited Members

- Protected Attributes inherited from tlp::WithParameter
ParameterDescriptionList parameters
 
- Protected Attributes inherited from tlp::WithDependency
std::list< Dependency_dependencies
 

Detailed Description

Top-level interface for plug-ins.

This class holds meta-information about a plug-in (group/author/version...). It stands as a unique base-class for every plugin type. This interface is not intended to be directly sublassed. Plugin objects are mainly used internally into the plugin lister system.

This classe also holds extra informations about the Tulip system such as the library version the plugin was built against. Plugin creation is handled by factories generated by the PLUGIN macro and the default Plugin constructor should never be called as is.

See Also
tlp::FactoryInterface for more advanced operation such as plugin creation and retrieving dependencies.
tlp::PluginContext and its subclasses for parameters handling.
tlp::Algorithm for plugins operating on the tlp::Graph structure.
tlp::TemplateAlgorithm and its subclasses for plugins operating on graph properties
tlp::View for panel plugins
tlp::Interactor for plugins responisble for user interactions.
tlp::Perspective for plugins handling the main GUI

Definition at line 70 of file Plugin.h.

Member Function Documentation

virtual std::string tlp::Plugin::author ( ) const
pure virtual

The name of the author of this plug-in.

Returns
the name of the author.
virtual std::string tlp::Plugin::category ( ) const
pure virtual

A string identifier for a plugin used for categorization purposes.

Returns
std::string the category of the plugin.

Implemented in tlp::StringAlgorithm, tlp::Perspective, tlp::SizeAlgorithm, tlp::LayoutAlgorithm, tlp::View, tlp::IntegerAlgorithm, tlp::Algorithm, tlp::DoubleAlgorithm, tlp::Interactor, tlp::ColorAlgorithm, tlp::BooleanAlgorithm, and tlp::PropertyAlgorithm.

virtual std::string tlp::Plugin::date ( ) const
pure virtual

The creation date of the plug-in. This date is in a free format, but most Tulip plug-ins use a DD/MM/YYYY.

Returns
the creation date.
virtual std::string tlp::Plugin::group ( ) const
pure virtual

Returns the name of the group this plug-in belongs to. Groups and sub-groups are separated by two colons. e.g. trees::planar trees.

Returns
the group name of this plug-in.
virtual std::string tlp::Plugin::icon ( ) const
virtual

The icon (preferably a thumbnail) of the plugin.

Returns
std::string the icon path

Reimplemented in tlp::Perspective, tlp::View, tlp::Algorithm, and tlp::Interactor.

virtual int tlp::Plugin::id ( ) const
virtual

Returns the ID of the glyph this factory builds. this member should be removed once there is a system in Tulip to handle glyphs.

Returns
int the id of the glyph.
virtual std::string tlp::Plugin::info ( ) const
pure virtual

Informations about the plug-in, from the plug-in author. These informations can contains anything, and the developer is completely free to put anything here. Most plug-ins by the Tulip team use an html format to generate help from these informations.

Returns
string The informations associated with this plug-in.
virtual std::string tlp::Plugin::major ( ) const
virtual

Only the major of the plug-in version. A version should be X.Y, X being the major.

Returns
The major part of the plug-in version.
virtual std::string tlp::Plugin::minor ( ) const
virtual

Only the minor of the plug-in version. A version should be X.Y, Y being the major.

Returns
The minor part of the plug-in version.
virtual std::string tlp::Plugin::name ( ) const
pure virtual

Returns the name of the plug-in, as registered in the Tulip plug-in system. This name must be unique, and if multiple plug-ins have the same name, only the latest encountered will be considered.

Returns
string the name of the plug-in.
virtual std::string tlp::Plugin::release ( ) const
pure virtual

The release version of the plug-in, including major and minor. The version should be X.Y, X being the major, and Y the minor.

Returns
string The release version.
virtual std::string tlp::Plugin::tulipMajor ( ) const
virtual
Returns
The major Tulip version the plug-in was built with.
virtual std::string tlp::Plugin::tulipMinor ( ) const
virtual
Returns
Return the minor Tulip version this plug-in was built with.
virtual std::string tlp::Plugin::tulipRelease ( ) const
pure virtual

The version of Tulip this plug-in was built with. Tulip versions are X.Y.Z, X eing the major, Y the minor, and Z the patch.

Returns
The Tulip version the plug-in was built with.