Classes
- class AbstractProperty
- This class is used to store a property of a graph. It implements PropertyInterface and add new methods to deal with two distinct type of values : More...
- class AbstractVectorProperty
- class SelfLoops
- class AcyclicTest
- Class for testing if the graph is acyclic. More...
- class Algorithm
- This abstract class describes a basic algorithm plugin. It inherits on WithParameter and WithDependency for convenience. Basic functionality consists in checking the algorithm can run on the current Graph (e.g. is the graph simple ?), running the algorithm and resetting the algorithm to re-apply it. The algorithm can and should report progress and which task it is performing if it is decomposed in multiple phases (e.g. layouting the graph, coloring it, ...). More...
- class AlgorithmPlugin
- A class for algorithm plug-ins The factory the registers itself in the Tulip plug-in system (through the static initFactory() method when the library is loaded.. The actual registration is delegated to a TemplateFactory for code factorization. More...
- struct Array
- Fixed-size array encapsulation. In debug mode, a bound check is performed at each access. More...
- class Bfs
- class BiconnectedTest
- class for testing if the graph is biconnected More...
- class BooleanAlgorithm
- Interface for selection plug-ins. More...
- class BooleanProperty
- class BooleanVectorProperty
- struct BoundingBox
- This class represents the 3D bounding box of an object. It is mostly used to determine whether or not two object are in a state of collision. More...
- struct Circle
- class for circle More...
- class Color
- class ColorAlgorithm
- Interface for color plug-ins. More...
- class ColorProperty
- class ColorVectorProperty
- class ColorScale
- This class represents a color scale to perform color mapping. The color scale can be either gradient or predefined colors steps. If the color scale is a gradient, returned colors are interpolated in function of the position. If the color scale isn't a gradient returned colors are the predefined colors steps. More...
- struct ConcatIterator
- This Iterator iterates over the sequence formed by the concatenation of the sequences it is given. More...
- class ConnectedTest
- class for testing if the graph is connected More...
- class ConversionIterator
- Iterator that enables to convert an Iterator of type TYPEIN to an Iterator if type TYPEOUT. More...
- class MPConversionIterator
- MPConversionIterator implements memory pool for ConversionIterator. More...
- class Coord
- This class represents a point in 3-D space, with float precision. More...
- class VoronoiDiagram
- class DoubleAlgorithm
- Interface for metric plug-ins. More...
- class DoubleProperty
- class DoubleVectorProperty
- struct edge
- class edge More...
- class ExportModule
- Interface for exportModule plug-ins. More...
- class ExportModuleFactory
- struct Face
- class face More...
- class FilterIterator
- Iterator that enables to filter an other Iterator. More...
- class MPFilterIterator
- MPFilterIterator implements memory pool for FilterIterator. More...
- class Graph
- Interface for a graph. More...
- class GraphEvent
- Event class for specific events on Graph. More...
- class GraphProperty
- class GraphStorageIdsMemento
- that class provides a simple interface to save the state of the ids manage by the GraphStorage class More...
- class GraphStorage
- That class provide a simple implementation for the storage of graph elts (nodes edges) More...
- class ImportModule
- Base class for import plug-ins. More...
- class ImportModuleFactory
- class IntegerAlgorithm
- Interface for int plug-ins. More...
- class IntegerProperty
- class IntegerVectorProperty
- struct Iterator
- Interface for Tulip iterators. Allows basic iteration operations only. More...
- class LayoutAlgorithm
- Interface for layout plug-ins. More...
- class LayoutProperty
- class CoordVectorProperty
- class Matrix
- class for mathematical square matrix More...
- class MemoryBlocks
- class MemoryPool
- That class enables to easily create a memory pool for an a class. More...
- class MutableContainer
- struct node
- class node More...
- class Event
- Event is the base class for all events used in the Observable/listener/Observer mechanism. More...
- class ObservableException
- ObservableException is the base class of all exceptions sent by the Observable/Listener/Observer system. More...
- class Observable
- Observable is the base class for the implementation of observable Object by Listener or Observer objects. More...
- class GraphObserver
- That class receives a message (call back/handler function) after each modification of a Graph. More...
- class PropertyObserver
- Observer for Property. More...
- class OuterPlanarTest
- class for testing the outerplanarity of a graph More...
- class PlanarityTest
- class for testing the planarity of a graph More...
- class PluginInfoInterface
- Base interface for plug-in description. This class is not intented to be subclassed by plug-ins themselves, but by the factories who create the plug-ins. This class holds user informations, such as name of the author, date of creation, and miscellaneous informations. It also holds informations for the Tulip plug-in system, such as the version (used to know when there is an update for a plug-in), the name (used as unique identifier to register the plug-in), the Tulip version the plug-in was built with (to know whether the plug-in is compatible with the currently running version of TUlip), and the group this plug-in belongs to (e.g. trees). More...
- class AlgorithmContext
- Parameter for calling clustering plugins. More...
- struct PluginLoader
- struct PluginLoaderTxt
- class PluginProgress
- Interface to notify and control the progression of a process. More...
- class PreferenceManager
- Class to manage preference Singleton class to load/store preference need by Tulip. More...
- class PropertyInterface
- class PropertyEvent
- Event class for specific events on PropertyInterface. More...
- class TypeInterface
- class SerializableType
- class SerializableVectorType
- class GraphType
- class EdgeSetType
- class DoubleType
- class FloatType
- class IntegerType
- class LongType
- class UnsignedIntegerType
- class BooleanType
- class BooleanVectorType
- class LineType
- class PointType
- class SizeType
- class StringType
- class StringVectorType
- class ColorType
- class QuadTreeNode
- QuadTree template class. More...
- struct Rectangle
- class for rectangle More...
- struct DataMem
- struct TypedValueContainer
- struct DataType
- struct TypedData
- struct DataTypeSerializer
- struct TypedDataSerializer
- class DataTypeSerializerContainer
- class DataSet
- A container which can store data of any type, as long as it has a well-defined copy constructor. More...
- struct StructDef
- This class enables to define a structure. More...
- class SimplePluginProgress
- Basic implementation for PluginProgress interface. More...
- class SimpleTest
- class Size
- class SizeAlgorithm
- Interface for sizes plug-ins. More...
- class SizeProperty
- class SizeVectorProperty
- struct SortNodeIterator
- This Iterator sorts the nodes in a sequence based on their values in a DoubleProperty. More...
- struct SortTargetEdgeIterator
- This Iterator sorts the edges based on the values of their target nodes in a DoubleProperty. More...
- class StableIterator
- Stores the elements of an iterator and iterates on a copy. More...
- class StlFilterIterator
- Iterator that enables to filter a Stl Iterator. More...
- class MPStlFilterIterator
- MPStlFilterIterator implements memory pool for StlFilterIterator. More...
- struct StlIterator
- class MPStlIterator
- MPStlIterator implements memory pool for StlIterator. More...
- struct StlMapIterator
- struct StlMapValueIterator
- class StringAlgorithm
- Interface for String plug-ins. More...
- struct StringCollection
- class StringProperty
- class StringVectorProperty
- class TemplateFactoryInterface
- This interface lists functions used to regroup plug-ins. More...
- class TemplateFactory
- This template class takes 3 parameters : More...
- class TreeTest
- Class for testing if the graph is a tree. More...
- class TriconnectedTest
- class for testing if a graph is triconnected More...
- class TulipException
- TulipException is a basic class to build exceptions from string. More...
- class CheckAllFunctor
- that class implement a default functor that always return true More...
- class UniqueIterator
- UniqueIterator enables to remove duplicated elements in an iterator. More...
- class MPUniqueIterator
- MPUniqueIterator implements memory pool for UniqueIterator. More...
- class Vector
- class for mathematical vector More...
- class VectorCast
- class for mathematical vector More...
- class VectorGraph
- That class provide a simple implementation of graph structure (without subgraphs, observer, metagraph) it enables to obtain very efficient access/modification time. More...
- class ValArrayInterface
- Internal class to access to a stl::vector in VectorGraph. More...
- class ValArray
- Internal class to access to a stl::vector in VectorGraph. More...
- class VectorGraphProperty
- That class enables to factorize code for NodeProperty and EdgeProperty in VectorGraph, it could not be used directly. More...
- class EdgeProperty
- That class enables to define a property/attribute on edges on a VectorGraph. More...
- class NodeProperty
- That class enables to define a property/attribute on nodes on a VectorGraph. More...
- struct Dependency
- Represents a single Tulip plug-in. More...
- class WithDependency
- Describes the dependencies of a plug-in on other plug-ins, identified by their name. This allows to have a plug-in inner workings depend on other plug-ins without linking them statically, or hoping depended plug-in will be there. More...
- class ParameterDescription
- Describes a parameter with a type, default value, whether or not is it mandatory and a help string describing what this parameter should be used for. More...
- struct ParameterDescriptionList
- This class describes parameters taken by a plugin. More...
- struct WithParameter
- This class describes parameters on a plug-in. More...
Typedefs
- typedef AbstractProperty
< tlp::ColorType,
tlp::ColorType,
tlp::ColorAlgorithm > AbstractColorProperty
- typedef AbstractProperty
< tlp::DoubleType,
tlp::DoubleType,
tlp::DoubleAlgorithm > AbstractDoubleProperty
- typedef AbstractProperty
< tlp::GraphType,
tlp::EdgeSetType > AbstractGraphProperty
- typedef AbstractProperty
< tlp::IntegerType,
tlp::IntegerType,
tlp::IntegerAlgorithm > AbstractIntegerProperty
- typedef AbstractProperty
< tlp::PointType,
tlp::LineType,
tlp::LayoutAlgorithm > AbstractLayoutProperty
- typedef _DEPRECATED Observable Observer
- typedef _DEPRECATED
PluginInfoInterface Plugin
- typedef AlgorithmContext PropertyContext
- typedef SerializableVectorType
< double, false > DoubleVectorType
- typedef SerializableVectorType
< int, false > IntegerVectorType
- typedef SerializableVectorType
< tlp::Size, true > SizeVectorType
- typedef SerializableVectorType
< tlp::Color, true > ColorVectorType
- typedef SerializableVectorType
< tlp::Coord, true > CoordVectorType
- typedef AbstractProperty
< tlp::SizeType, tlp::SizeType,
tlp::SizeAlgorithm > AbstractSizeProperty
- typedef AbstractProperty
< tlp::StringType,
tlp::StringType,
tlp::StringAlgorithm > AbstractStringProperty
- typedef Vector< unsigned int, 2 > Vec2ui
- typedef for 2D vector of unsigned int
- typedef Vector< unsigned int, 3 > Vec3ui
- typedef for 3D vector of unsigned int
- typedef Vector< unsigned int, 4 > Vec4ui
- typedef for 4D vector of unsigned int
- typedef Vector< int, 2 > Vec2i
- typedef for 2D vector of int
- typedef Vector< int, 3 > Vec3i
- typedef for 3D vector of int
- typedef Vector< int, 4 > Vec4i
- typedef for 4D vector of int
- typedef Vector< double, 2 > Vec2d
- typedef for 2D vector of double
- typedef Vector< double, 3 > Vec3d
- typedef for 3D vector of double
- typedef Vector< double, 4 > Vec4d
- typedef for 4D vector of double
- typedef Vector< float, 2 > Vec2f
- typedef for 2D vector of float
- typedef Vector< float, 3 > Vec3f
- typedef for 3D vector of float
- typedef Vector< float, 4 > Vec4f
- typedef for 4D vector of float
Enumerations
Functions
- template<typename Obj , unsigned int SIZE> std::ostream & operator<< (std::ostream &os, const Array< Obj, SIZE > &array)
- template<typename Obj , unsigned int SIZE> std::istream & operator>> (std::istream &is, Array< Obj, SIZE > &)
- template<typename Obj > bool intersection (const Circle< Obj > &c1, const Circle< Obj > &c2, Vector< Obj, 2 > &sol1, Vector< Obj, 2 > &sol2)
- template<typename Obj > Circle< Obj > enclosingCircle (const Circle< Obj > &, const Circle< Obj > &)
- template<typename Obj > Circle< Obj > enclosingCircle (const std::vector< Circle< Obj > > &circles)
- template<typename Obj > Circle< Obj > lazyEnclosingCircle (const std::vector< Circle< Obj > > &circles)
- template<typename Obj > std::ostream & operator<< (std::ostream &os, const Circle< Obj > &)
- TLP_SCOPE std::ostream & operator<< (std::ostream &os, const tlp::Color &)
- TLP_SCOPE std::istream & operator>> (std::istream &is, tlp::Color &)
- TLP_SCOPE void convexHull (const std::vector< Coord > &points, std::vector< unsigned int > &convexHull)
- function for convex hull manipulation
- TLP_SCOPE void mergeHulls (const std::vector< Coord > &points, const std::vector< unsigned int > &hull1, const std::vector< unsigned int > &hull2, std::vector< unsigned int > &mergedConvexHull)
- TLP_SCOPE void intersectHulls (std::vector< Coord > &points, const std::vector< unsigned int > &hull1, const std::vector< unsigned int > &hull2, std::vector< unsigned int > &intersection)
- TLP_SCOPE double areaOfHull (const std::vector< Coord > &points, const std::vector< unsigned int > &hull)
- TLP_SCOPE bool insideHull (const std::vector< Coord > &points, const std::vector< unsigned int > &hull, const Coord &point)
- TLP_SCOPE bool delaunayTriangulation (std::vector< Coord > &points, std::vector< std::pair< unsigned int, unsigned int > > &edges, std::vector< std::vector< unsigned int > > &simplices, bool voronoiMode=false)
- functions for Delaunay Triangulations
- TLP_SCOPE bool voronoiDiagram (std::vector< Coord > &sites, VoronoiDiagram &voronoiDiagram)
- TLP_SCOPE BoundingBox computeBoundingBox (const Graph *graph, const LayoutProperty *layout, const SizeProperty *size, const DoubleProperty *rotation, const BooleanProperty *selection=NULL)
- TLP_SCOPE BoundingBox computeBoundingBox (Iterator< node > *itN, Iterator< edge > *itE, const LayoutProperty *layout, const SizeProperty *size, const DoubleProperty *rotation, const BooleanProperty *selection=NULL)
- TLP_SCOPE std::pair< Coord, Coord > computeBoundingRadius (const Graph *graph, const LayoutProperty *layout, const SizeProperty *size, const DoubleProperty *rotation, const BooleanProperty *selection=NULL)
- TLP_SCOPE std::vector< Coord > computeConvexHull (const Graph *graph, const LayoutProperty *layout, const SizeProperty *size, const DoubleProperty *rotation, const BooleanProperty *selection=NULL)
- TLP_SCOPE std::vector< Coord > computeConvexHull (const std::vector< tlp::Coord > &points)
- TLP_SCOPE bool computeLinesIntersection (const std::pair< tlp::Coord, tlp::Coord > &line1, const std::pair< tlp::Coord, tlp::Coord > &line2, tlp::Coord &intersectionPoint)
- TLP_SCOPE tlp::Coord computePolygonCentroid (const std::vector< tlp::Coord > &points)
- void openMetaNode (Graph *graph, node n)
- node createMetaNode (Graph *graph, const std::set< node > &nodeSet)
- Graph * inducedSubGraph (Graph *graph, const std::set< node > &nodeSet)
- TLP_SCOPE Graph * loadGraph (const std::string &filename)
- Loads a graph in the tlp format from a file (extension can be .tlp or .tlp.gz). This function uses the "tlp" import plugin, and will fail if it is not loaded (By default this plugin is linked into the library and should be loaded).
- TLP_SCOPE bool saveGraph (Graph *g, const std::string &filename)
- Saves the corresponding root graph and all its subgraphs to a file using the tlp format. Extension of the file can be either .tlp (human-readable text file) or .tlp.gz (gzipped text file).
- TLP_SCOPE bool exportGraph (Graph *graph, std::ostream &outputStream, const std::string &format, DataSet &dataSet, PluginProgress *progress=NULL)
- Exports a graph using the specified export plugin with parameters stored in the DataSet.
- TLP_SCOPE Graph * importGraph (const std::string &format, DataSet &dataSet, PluginProgress *progress=NULL, Graph *newGraph=NULL)
- Imports a graph using the specified import plugin with the parameters stored in the DataSet.
- TLP_SCOPE _DEPRECATED bool applyAlgorithm (Graph *graph, std::string &errorMsg, DataSet *dataSet=NULL, const std::string &algorithm="any", PluginProgress *progress=NULL)
- Applies an algorithm plugin, identified by its name.
- TLP_SCOPE Graph * newGraph ()
- Creates and returns a new empty graph.
- TLP_SCOPE _DEPRECATED Graph * newSubGraph (Graph *root, std::string name="unnamed")
- Creates and returns an empty subgraph of the given graph.
- TLP_SCOPE _DEPRECATED Graph * newCloneSubGraph (Graph *root, std::string name="unnamed")
- Creates and returns a subgraph of the graph that is equal to root (a clone subgraph).
- TLP_SCOPE _DEPRECATED bool getSource (const Graph *, node &n)
- Finds the first node whose input degree equals 0.
- TLP_SCOPE void copyToGraph (Graph *outG, const Graph *inG, BooleanProperty *inSelection=NULL, BooleanProperty *outSelection=NULL)
- TLP_SCOPE void removeFromGraph (Graph *ioG, BooleanProperty *inSelection=NULL)
- TLP_SCOPE double averagePathLength (const Graph *g, PluginProgress *=NULL)
- bool averagePathLength (Graph *g, double &result, PluginProgress *pp=NULL)
- TLP_SCOPE double averageClusteringCoefficient (const Graph *, PluginProgress *=0)
- bool averageCluster (Graph *g, double &result, PluginProgress *pp=NULL)
- TLP_SCOPE void clusteringCoefficient (const Graph *g, MutableContainer< double > &result, unsigned int maxDepth=1, PluginProgress *=NULL)
- TLP_SCOPE void dagLevel (const Graph *graph, MutableContainer< unsigned int > &level, PluginProgress *=NULL)
- TLP_SCOPE unsigned int maxDegree (const Graph *)
- TLP_SCOPE unsigned int minDegree (const Graph *)
- TLP_SCOPE unsigned int maxDistance (const Graph *graph, const node n, MutableContainer< unsigned int > &distance, EDGE_TYPE direction=UNDIRECTED)
- TLP_SCOPE void reachableNodes (const Graph *graph, const node startNode, std::set< node > &result, unsigned int maxDistance, EDGE_TYPE direction=UNDIRECTED)
- TLP_SCOPE std::vector
< std::vector< node > > computeCanonicalOrdering (PlanarConMap *, std::vector< edge > *dummyEdges=NULL, PluginProgress *pluginProgress=NULL)
- TLP_SCOPE std::vector< node > computeGraphCenters (Graph *graph)
- TLP_SCOPE node graphCenterHeuristic (Graph *graph, PluginProgress *pluginProgress=NULL)
- TLP_SCOPE node makeSimpleSource (Graph *graph)
- TLP_SCOPE void makeProperDag (Graph *graph, std::list< node > &addedNodes, TLP_HASH_MAP< edge, edge > &replacedEdges, IntegerProperty *edgeLength=NULL)
- TLP_SCOPE void selectSpanningForest (Graph *graph, BooleanProperty *selectionProperty, PluginProgress *pluginProgress=NULL)
- TLP_SCOPE void selectSpanningTree (Graph *graph, BooleanProperty *selection, PluginProgress *pluginProgress=NULL)
- TLP_SCOPE void selectMinimumSpanningTree (Graph *graph, BooleanProperty *selectionProperty, DoubleProperty *weight=NULL, PluginProgress *pluginProgress=NULL)
- TLP_SCOPE bool computeEqualValueClustering (Graph *graph, PropertyInterface *property, bool onNodes=true, bool connected=false, PluginProgress *pluginProgress=NULL)
- template<typename Obj , unsigned int SIZE> MATRIX operator+ (const MATRIX &mat1, const MATRIX &mat2)
- template<typename Obj , unsigned int SIZE> MATRIX operator- (const MATRIX &mat1, const MATRIX &mat2)
- template<typename Obj , unsigned int SIZE> MATRIX operator* (const MATRIX &mat, const Obj &obj)
- template<typename Obj , unsigned int SIZE> MATRIX operator* (const MATRIX &mat1, const MATRIX &mat2)
- template<typename Obj , unsigned int SIZE> Vector< Obj, SIZE > operator* (const Vector< Obj, SIZE > &vec, const tlp::Matrix< Obj, SIZE > &)
- template<typename Obj , unsigned int SIZE> Vector< Obj, SIZE > operator* (const Matrix< Obj, SIZE > &, const Vector< Obj, SIZE > &vec)
- TLP_SCOPE void initTypeSerializers ()
- TLP_SCOPE void initTulipLib (const char *appDirPath=0)
- Initializes the Tulip library. Looks for the Tulip plugins directory and fills the Tulip path variables : tlp::TulipLibDir, tlp::TulipPluginsPath, ... The plug-ins directory can be defined in different ways, given by order of prevalence : 1. the TLP_DIR environment variable, if it has a value 2. the appDirPath parameter, if it is not NULL 3. at that point, the Tulip paths will be retrieved from the path of the loaded Tulip shared library (you must dispose of a standard Tulip installation for that feature to work). 4. a fallback value of 'C:/Tulip/lib/' on windows, or '/usr/local/lib/' on unix.
- TLP_SCOPE void loadPlugins (PluginLoader *plug=NULL)
- Calls loadPluginsFromDir for each directory in TulipPluginsPath.
- TLP_SCOPE bool loadPlugin (const std::string &filename, PluginLoader *plug=NULL)
- TLP_SCOPE void loadPluginsFromDir (std::string dir, std::string type, PluginLoader *loader=NULL)
- TLP_SCOPE void loadPluginsCheckDependencies (PluginLoader *loader=NULL)
- TLP_SCOPE std::string demangleTlpClassName (const char *className)
- Demangles the name of a C++ class defined in the tlp namespace. Simply removes the 'tlp::' prefix from the class name.
- TLP_SCOPE std::istream * getIgzstream (const char *name, int open_mode=std::ios::in)
- Returns an istream to read from a gzipped file (uses gzstream lib). The stream has to be deleted after use.
- TLP_SCOPE std::ostream * getOgzstream (const char *name, int open_mode=std::ios::out)
- Returns an ostream to write to a gzipped file (uses gzstream lib). The stream has to be deleted after use.
- TLP_SCOPE std::string getMajor (const std::string &release)
- Splits the string and returns everything before the first dot ('.'). This is used to return major version number, as version numbers are formatted as X.Y.Z, X being the major, Y the minor, and Z the patch version.
- TLP_SCOPE std::string getMinor (const std::string &release)
- Splits the string and return the minor version. If the string does not contain any dot, then 0 is returned. If the string contains only one dot (X.Y), then everything after the first dot is returned (Y). If the string is a full version with two dots (X.Y.Z), everything between the first and last dots is returned (Y). If there are more than two dots, everything between the first and last dots is returned.
- TLP_SCOPE const std::string & getCurrentPluginFileName ()
- Gets the plugin library currently loading Returns the absolute file name of the plugin library currently loading.
- bool stringToColor (std::string &str, Color &col)
- bool stringToSize (std::string &str, Size &siz)
- bool stringToCoord (std::string &str, Coord &coo)
- bool stringToLCoord (std::string &str, std::list< Coord > &lcoo)
- bool stringToNodeProperty (PropertyInterface *propertyName, node n, std::string &str)
- bool stringToEdgeProperty (PropertyInterface *propertyName, edge e, std::string &str)
- bool stringToAllNodeProperty (PropertyInterface *propertyName, std::string &str)
- bool stringToAllEdgeProperty (PropertyInterface *propertyName, std::string &str)
- std::string nodePropertyToString (PropertyInterface *propertyName, node n)
- std::string edgePropertyToString (PropertyInterface *propertyName, edge e)
- std::string propertyType (PropertyInterface *propertyName)
- std::string propertyNodeDefaultValue (PropertyInterface *propertyName)
- std::string propertyEdgeDefaultValue (PropertyInterface *propertyName)
- TEMPLATEVECTOR VECTOR minVector (const VECTOR &u, const VECTOR &v)
- TEMPLATEVECTOR VECTOR maxVector (const VECTOR &u, const VECTOR &v)
- TEMPLATEVECTOR VECTOR operator* (const VECTOR &, const VECTOR &)
- TEMPLATEVECTOR VECTOR operator* (const TYPE &, const VECTOR &)
- TEMPLATEVECTOR VECTOR operator* (const VECTOR &, const TYPE &)
- TEMPLATEVECTOR VECTOR operator+ (const VECTOR &, const VECTOR &)
- TEMPLATEVECTOR VECTOR operator+ (const VECTOR &, const TYPE &)
- TEMPLATEVECTOR VECTOR operator- (const VECTOR &, const VECTOR &)
- TEMPLATEVECTOR VECTOR operator- (const VECTOR &, const TYPE &)
- TEMPLATEVECTOR VECTOR operator/ (const VECTOR &, const VECTOR &)
- TEMPLATEVECTOR VECTOR operator/ (const VECTOR &, const TYPE &)
- TEMPLATEVECTOR VECTOR operator^ (const VECTOR &, const VECTOR &)
- TEMPLATEVECTOR VECTOR operator- (const VECTOR &)
Variables
Detailed Description
This file is part of Tulip (www.tulip-software.org)
Authors: David Auber and the Tulip development Team from LaBRI, University of Bordeaux 1 and Inria Bordeaux - Sud Ouest
Tulip is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
Tulip is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
Typedef Documentation
Enumeration Type Documentation
- Enumerator:
DIRECTED |
|
INV_DIRECTED |
|
UNDIRECTED |
|
- Enumerator:
TLP_CONTINUE |
|
TLP_CANCEL |
|
TLP_STOP |
|
Function Documentation
TLP_SCOPE _DEPRECATED bool tlp::applyAlgorithm |
( |
Graph * |
graph, |
|
|
std::string & |
errorMsg, |
|
|
DataSet * |
dataSet = NULL , |
|
|
const std::string & |
algorithm = "any" , |
|
|
PluginProgress * |
progress = NULL |
|
) |
| |
Applies an algorithm plugin, identified by its name.
Applies an algorithm plugin named alg (must be loaded) on graph . Algorithm plugins are objects implementing the tlp::Algorithm interface. Parameters can be transmit to the algorithm trough a DataSet object (refer to the plugin documentation to get its parameters list). If an error occurs, a message may have been stored by the algorithm in the errosMsg variable. Returns true if the algorithm has been successfully applied.
- Deprecated:
- this function should not be used anymore, please use Graph::applyAlgorithm() instead.
If an error occurs, a message describing the error should be stored in errorMessage.
- Parameters:
-
graph | A graph for which the algorithm must be applied. |
errorMessage | A string that will be modified to contain an error message should an error occur. |
dataSet | The parameters to the algorithm. Defaults to NULL. |
algorithm | The algorithm to apply. Defaults to "any". |
progress | A PluginProgress to report the progress of the operation, as well as final state. Defaults to NULL. |
- Returns:
- bool Whether the algorithm was successfully applied.
bool tlp::averageCluster |
( |
Graph * |
g, |
|
|
double & |
result, |
|
|
PluginProgress * |
pp = NULL |
|
) |
| [inline] |
TLP_SCOPE double tlp::averageClusteringCoefficient |
( |
const Graph * |
, |
|
|
PluginProgress * |
= 0 |
|
) |
| |
bool tlp::averagePathLength |
( |
Graph * |
g, |
|
|
double & |
result, |
|
|
PluginProgress * |
pp = NULL |
|
) |
| [inline] |
TLP_SCOPE double tlp::averagePathLength |
( |
const Graph * |
g, |
|
|
PluginProgress * |
= NULL |
|
) |
| |
Returns the average path length of a graph, that is the sum of the shortest distances for all pair of distinct nodes in that graph divided by the number of those pairs. For a pair of non connected nodes, the shorted distance is set to 0. see http://en.wikipedia.org/wiki/Average_path_length for more details
TLP_SCOPE void tlp::clusteringCoefficient |
( |
const Graph * |
g, |
|
|
MutableContainer< double > & |
result, |
|
|
unsigned int |
maxDepth = 1 , |
|
|
PluginProgress * |
= NULL |
|
) |
| |
Assigns to each node its local clustering coefficient that is the proportion of edges between the nodes within its neighbourhood divided by the number of edges that could possibly exist between them. This quantifies how close its neighbors are to being a clique. see http://en.wikipedia.org/wiki/Clustering_coefficient for more details
TLP_SCOPE BoundingBox tlp::computeBoundingBox |
( |
const Graph * |
graph, |
|
|
const LayoutProperty * |
layout, |
|
|
const SizeProperty * |
size, |
|
|
const DoubleProperty * |
rotation, |
|
|
const BooleanProperty * |
selection = NULL |
|
) |
| |
Computes the bounding box of a graph according to nodes positions, edges bends, nodes z-rotations and sizes of elements.
TLP_SCOPE BoundingBox tlp::computeBoundingBox |
( |
Iterator< node > * |
itN, |
|
|
Iterator< edge > * |
itE, |
|
|
const LayoutProperty * |
layout, |
|
|
const SizeProperty * |
size, |
|
|
const DoubleProperty * |
rotation, |
|
|
const BooleanProperty * |
selection = NULL |
|
) |
| |
Compute the bounding box of graph elements according to node positions, edges bends, nodes z-rotations and sizes of elements.
Iterator itN and itE will be deleted after the computations (i.e. no need to delete them yourself).
TLP_SCOPE std::pair<Coord, Coord> tlp::computeBoundingRadius |
( |
const Graph * |
graph, |
|
|
const LayoutProperty * |
layout, |
|
|
const SizeProperty * |
size, |
|
|
const DoubleProperty * |
rotation, |
|
|
const BooleanProperty * |
selection = NULL |
|
) |
| |
Computes a bounding sphere (or a bounding circle if the graph has a 2D layout) of a graph according to nodes positions, edges bends, nodes z-rotations and sizes of elements.
Returns a pair of tlp::Coord whose first member is the center of the bounding sphere (circle for 2D layout) and second member is the farthest point from the center (computed from graph elements positions). To get the bounding radius, you have to compute the distance between the two members of the pair (use the dist method from tlp::Coord).
TLP_SCOPE std::vector<std::vector<node> > tlp::computeCanonicalOrdering |
( |
PlanarConMap * |
, |
|
|
std::vector< edge > * |
dummyEdges = NULL , |
|
|
PluginProgress * |
pluginProgress = NULL |
|
) |
| |
This ordering was first introduced by C. Gutwenger and P. Mutzel in
"Grid embeddings of biconnected planar graphs",
"Extended Abstract, Max-Planck-Institut für Informatik,"
"Saarbrücken, Germany, 1997"
Let n be the number of nodes, the original algorithm complexity is in O(n).
But the implementation of the canonical ordering has not been made in O(n).
TLP_SCOPE std::vector<Coord> tlp::computeConvexHull |
( |
const Graph * |
graph, |
|
|
const LayoutProperty * |
layout, |
|
|
const SizeProperty * |
size, |
|
|
const DoubleProperty * |
rotation, |
|
|
const BooleanProperty * |
selection = NULL |
|
) |
| |
Computes a convex hull of a graph according to nodes positions, edges bends, nodes z-rotations, and sizes of elements. Only works with 2D layouts.
Returns a vector of tlp::Coord containing the vertices of the graph convex hull correctly ordered.
TLP_SCOPE std::vector<Coord> tlp::computeConvexHull |
( |
const std::vector< tlp::Coord > & |
points | ) |
|
Computes a convex hull of a set of points, Only works with 2D layouts.
Returns a vector of tlp::Coord containing the vertices of the points convex hull correctly ordered.
TLP_SCOPE bool tlp::computeEqualValueClustering |
( |
Graph * |
graph, |
|
|
PropertyInterface * |
property, |
|
|
bool |
onNodes = true , |
|
|
bool |
connected = false , |
|
|
PluginProgress * |
pluginProgress = NULL |
|
) |
| |
Compute the subgraphs whose elements have the same value for property
TLP_SCOPE std::vector<node> tlp::computeGraphCenters |
( |
Graph * |
graph | ) |
|
Find all the graph centers, that version does not manage edge weight. complexity O(n * m). Only works on connected graphs.
Computes the intersection point (if any) of two 3d lines. Returns true if the line intersects, false otherwise (parallel or skew lines).
Computes the centroid of a polygon. Polygon vertices must be provided correctly ordered in the points vector.
TLP_SCOPE void tlp::copyToGraph |
( |
Graph * |
outG, |
|
|
const Graph * |
inG, |
|
|
BooleanProperty * |
inSelection = NULL , |
|
|
BooleanProperty * |
outSelection = NULL |
|
) |
| |
Appends the selected part of the graph inG (properties, nodes and edges) into the graph outG. If no selection is done (inSel=NULL), the whole inG graph is appended. The output selection is used to select the appended nodes & edges
- Warning:
- The input selection is extended to all selected edge ends.
node tlp::createMetaNode |
( |
Graph * |
graph, |
|
|
const std::set< node > & |
nodeSet |
|
) |
| [inline] |
Function to close a subgraph into a metanode. Edges from nodes in the subgraph to nodes outside the subgraph are replaced with edges from the metanode to the nodes outside the subgraph.
TLP_SCOPE void tlp::dagLevel |
( |
const Graph * |
graph, |
|
|
MutableContainer< unsigned int > & |
level, |
|
|
PluginProgress * |
= NULL |
|
) |
| |
Assigns to each node of a Directed Acyclic Graph a level such that if the edge e(u,v) exists level(u) < level(v). The algorithm ensures that the number of level used is minimal.
Warning : the graph must be acyclic (no self loops).
TLP_SCOPE std::string tlp::demangleTlpClassName |
( |
const char * |
className | ) |
|
Demangles the name of a C++ class defined in the tlp namespace. Simply removes the 'tlp::' prefix from the class name.
- Returns:
- string The demangled name of a Tulip C++ class.
TLP_SCOPE bool tlp::exportGraph |
( |
Graph * |
graph, |
|
|
std::ostream & |
outputStream, |
|
|
const std::string & |
format, |
|
|
DataSet & |
dataSet, |
|
|
PluginProgress * |
progress = NULL |
|
) |
| |
Exports a graph using the specified export plugin with parameters stored in the DataSet.
You determine the destination, whether by using a fstream, or by saving the contents of the stream to the destination of your choice.
- Parameters:
-
graph | The graph to export. |
outputStream | The stream to export to. Can be a standard ostream, an ofstream, or even a gzipped ostream. |
format | The format to use to export the Graph. |
dataSet | The parameters to pass to the export plugin (e.g. additional data, options for the format) |
progress | A PluginProgress to report the progress of the operation, as well as final state. Defaults to NULL. |
- Returns:
- bool Whether the export was successfull or not.
TLP_SCOPE const std::string& tlp::getCurrentPluginFileName |
( |
| ) |
|
Gets the plugin library currently loading Returns the absolute file name of the plugin library currently loading.
TLP_SCOPE std::istream* tlp::getIgzstream |
( |
const char * |
name, |
|
|
int |
open_mode = std::ios::in |
|
) |
| |
Returns an istream to read from a gzipped file (uses gzstream lib). The stream has to be deleted after use.
- Parameters:
-
name | The name of the file to read from. |
open_mode | The mode to open the file with. Defaults to std::ios::in. |
- Returns:
- istream gzipped input stream from a file.
TLP_SCOPE std::string tlp::getMajor |
( |
const std::string & |
release | ) |
|
Splits the string and returns everything before the first dot ('.'). This is used to return major version number, as version numbers are formatted as X.Y.Z, X being the major, Y the minor, and Z the patch version.
- Returns:
- string The part of the string before the first dot.
TLP_SCOPE std::string tlp::getMinor |
( |
const std::string & |
release | ) |
|
Splits the string and return the minor version. If the string does not contain any dot, then 0 is returned. If the string contains only one dot (X.Y), then everything after the first dot is returned (Y). If the string is a full version with two dots (X.Y.Z), everything between the first and last dots is returned (Y). If there are more than two dots, everything between the first and last dots is returned.
TLP_SCOPE std::ostream* tlp::getOgzstream |
( |
const char * |
name, |
|
|
int |
open_mode = std::ios::out |
|
) |
| |
Returns an ostream to write to a gzipped file (uses gzstream lib). The stream has to be deleted after use.
- Warning:
- Don't forget to check the stream with ios::bad()!
- Parameters:
-
name | The name of the file to write to. |
open_mode | The mode to open the file with. Defaults to std::ios::out. |
- Returns:
- ostream gzipped output stream to a file.
TLP_SCOPE _DEPRECATED bool tlp::getSource |
( |
const Graph * |
, |
|
|
node & |
n |
|
) |
| |
Finds the first node whose input degree equals 0.
- Deprecated:
- this function should not be used anymore, please use Graph::getSource() instead.
- Returns:
- tlp::node The first encountered node with input degree of 0, or an invalid node if none was found.
TLP_SCOPE node tlp::graphCenterHeuristic |
( |
Graph * |
graph, |
|
|
PluginProgress * |
pluginProgress = NULL |
|
) |
| |
return a node that can be considered as the graph center. It is an heuristic, thus it is not absolutely sure that this node is a graph center. Only works on connected graphs.
TLP_SCOPE Graph* tlp::importGraph |
( |
const std::string & |
format, |
|
|
DataSet & |
dataSet, |
|
|
PluginProgress * |
progress = NULL , |
|
|
Graph * |
newGraph = NULL |
|
) |
| |
Imports a graph using the specified import plugin with the parameters stored in the DataSet.
If no graph is passed, then a new graph will be created. You can pass a graph in order to import data into it. Returns the graph with imported data, or NULL if the import failed. In this case, the Pluginprogress should have an error that can be displayed.
- Parameters:
-
format | The format to use to import the graph. |
dataSet | The parameters to pass to the import plugin (file to read, ...) |
progress | A PluginProgress to report the progress of the operation, as well as final state. Defaults to NULL. |
newGraph | The graph to import the data into. This can be usefull to import data into a subgraph. Defaults to NULL. |
- Returns:
- :Graph* The graph containing the imported data, or NULL in case of failure.
Graph* tlp::inducedSubGraph |
( |
Graph * |
graph, |
|
|
const std::set< node > & |
nodeSet |
|
) |
| [inline] |
Return the subgraph induced by a set of nodes
TLP_SCOPE void tlp::initTulipLib |
( |
const char * |
appDirPath = 0 | ) |
|
Initializes the Tulip library. Looks for the Tulip plugins directory and fills the Tulip path variables : tlp::TulipLibDir, tlp::TulipPluginsPath, ... The plug-ins directory can be defined in different ways, given by order of prevalence : 1. the TLP_DIR environment variable, if it has a value 2. the appDirPath parameter, if it is not NULL 3. at that point, the Tulip paths will be retrieved from the path of the loaded Tulip shared library (you must dispose of a standard Tulip installation for that feature to work). 4. a fallback value of 'C:/Tulip/lib/' on windows, or '/usr/local/lib/' on unix.
TLP_SCOPE void tlp::initTypeSerializers |
( |
| ) |
|
TLP_SCOPE Graph* tlp::loadGraph |
( |
const std::string & |
filename | ) |
|
Loads a graph in the tlp format from a file (extension can be .tlp or .tlp.gz). This function uses the "tlp" import plugin, and will fail if it is not loaded (By default this plugin is linked into the library and should be loaded).
If the import fails (no such file, parse error, ...) NULL is returned.
- Parameters:
-
filename | The file in tlp format to parse. |
- Returns:
- :Graph* The imported Graph, NULL if the import failed.
TLP_SCOPE bool tlp::loadPlugin |
( |
const std::string & |
filename, |
|
|
PluginLoader * |
plug = NULL |
|
) |
| |
Loads a plugin from a specific shared library.
- Parameters:
-
filename | the path to the shared library containing the Tulip plugin (file extension : .so on linux, .dylib on mac, .dll on windows) |
plug | A PluginLoader to output what is going on. Defaults to 0. |
- Returns:
- bool true if the plugin was correctly loaded
TLP_SCOPE void tlp::loadPlugins |
( |
PluginLoader * |
plug = NULL | ) |
|
Calls loadPluginsFromDir for each directory in TulipPluginsPath.
Loads plugins installed in the directories listed in the tlp::TulipPluginsPath variable (in the form "<path1>;<path2>" on windows and "<path1>:<path2>" on unix)
- Parameters:
-
plug | A PluginLoader to output what is going on. Defaults to 0. |
TLP_SCOPE void tlp::loadPluginsCheckDependencies |
( |
PluginLoader * |
loader = NULL | ) |
|
Checks the dependencies of all plugins loaded so far. If a plugin does not have all its dependencies fulfilled, it is unloaded and removed from the current plugins database.
- Parameters:
-
loader | A PluginLoader to output what is going on. Defaults to 0. |
TLP_SCOPE void tlp::loadPluginsFromDir |
( |
std::string |
dir, |
|
|
std::string |
type, |
|
|
PluginLoader * |
loader = NULL |
|
) |
| |
Loads plugins located in a specific directory
- Parameters:
-
dir | the path to the directory containing the Tulip plugins |
type | a string used by the plugin loader (if any) to output the type of plugin being loaded |
loader | A PluginLoader to output what is going on. Defaults to 0. |
TLP_SCOPE void tlp::makeProperDag |
( |
Graph * |
graph, |
|
|
std::list< node > & |
addedNodes, |
|
|
TLP_HASH_MAP< edge, edge > & |
replacedEdges, |
|
|
IntegerProperty * |
edgeLength = NULL |
|
) |
| |
TLP_SCOPE node tlp::makeSimpleSource |
( |
Graph * |
graph | ) |
|
return a new node connected to all previously existing nodes which had a null indegree
TLP_SCOPE unsigned int tlp::maxDegree |
( |
const Graph * |
| ) |
|
Returns the maximum value of the degree of the graph's nodes.
TLP_SCOPE unsigned int tlp::maxDistance |
( |
const Graph * |
graph, |
|
|
const node |
n, |
|
|
MutableContainer< unsigned int > & |
distance, |
|
|
EDGE_TYPE |
direction = UNDIRECTED |
|
) |
| |
Computes the maximum distance from n to all the other nodes of the graph and store it into distance (stored value is UINT_MAX for non connected nodes). If direction is set to 2 use undirected graph, 0 use directed graph and 1 use reverse directed graph (ie. all edges are reversed). All the edge's weight is set to 1. (it uses a bfs thus the complexity is o(m), m = |E|).
TLP_SCOPE unsigned int tlp::minDegree |
( |
const Graph * |
| ) |
|
Returns the minimum value of the degree of the graph's nodes.
TLP_SCOPE _DEPRECATED Graph* tlp::newCloneSubGraph |
( |
Graph * |
root, |
|
|
std::string |
name = "unnamed" |
|
) |
| |
Creates and returns a subgraph of the graph that is equal to root (a clone subgraph).
- Deprecated:
- this function should not be used anymore, please use Graph::addCloneSubGraph() instead.
- Parameters:
-
graph | The Graph on which to create a clone subgraph. |
name | The name of the newly created subgraph. Defaults to "unnamed". |
- Returns:
- :Graph* The newly created clone subgraph.
TLP_SCOPE Graph* tlp::newGraph |
( |
| ) |
|
Creates and returns a new empty graph.
This is a simple method factory to create a Graph implementation (remember, Graph is only an interface).
This is the recommended way to create a new Graph.
- Returns:
- :Graph* A new, empty graph.
- Examples:
- PrintObserver.
TLP_SCOPE _DEPRECATED Graph* tlp::newSubGraph |
( |
Graph * |
root, |
|
|
std::string |
name = "unnamed" |
|
) |
| |
Creates and returns an empty subgraph of the given graph.
- Deprecated:
- this function should not be used anymore, please use Graph::addSubGraph() instead.
- Parameters:
-
graph | The graph to add an empty subgraph to. |
name | The name of the new subgraph. Defaults to "unnamed". |
- Returns:
- :Graph* The newly created subgraph.
void tlp::openMetaNode |
( |
Graph * |
graph, |
|
|
node |
n |
|
) |
| [inline] |
Function to open a metanode and replace all edges between that meta node and other nodes in the graph.
TLP_SCOPE std::ostream& tlp::operator<< |
( |
std::ostream & |
os, |
|
|
const tlp::Color & |
|
|
) |
| |
TLP_SCOPE std::istream& tlp::operator>> |
( |
std::istream & |
is, |
|
|
tlp::Color & |
|
|
) |
| |
TLP_SCOPE void tlp::reachableNodes |
( |
const Graph * |
graph, |
|
|
const node |
startNode, |
|
|
std::set< node > & |
result, |
|
|
unsigned int |
maxDistance, |
|
|
EDGE_TYPE |
direction = UNDIRECTED |
|
) |
| |
Adds to a result set, all the nodes, according to direction, at distance less or equal to maxDistance of startNode.
TLP_SCOPE void tlp::removeFromGraph |
( |
Graph * |
ioG, |
|
|
BooleanProperty * |
inSelection = NULL |
|
) |
| |
Removes the selected part of the graph ioG (properties values, nodes and edges). If no selection is done (inSel=NULL), the whole graph is reseted to default value.
- Warning:
- The selection is extended to all selected edge ends.
TLP_SCOPE bool tlp::saveGraph |
( |
Graph * |
g, |
|
|
const std::string & |
filename |
|
) |
| |
Saves the corresponding root graph and all its subgraphs to a file using the tlp format. Extension of the file can be either .tlp (human-readable text file) or .tlp.gz (gzipped text file).
This function checks the file name for the '.gz' extension and uses a compressed output if found.
This function uses the "tlp" export plugin, and will fail if it is not loaded (by default this plugin is linked into the library and should be loaded).
- Parameters:
-
g | The graph to save. |
filename | The file to save the graph to. |
- Returns:
- bool Whether the export was successfull or not.
TLP_SCOPE void tlp::selectMinimumSpanningTree |
( |
Graph * |
graph, |
|
|
BooleanProperty * |
selectionProperty, |
|
|
DoubleProperty * |
weight = NULL , |
|
|
PluginProgress * |
pluginProgress = NULL |
|
) |
| |
Select the minimum spanning tree (Kruskal algorithm) of a weighted graph, i.e for all graph elements (nodes or edges) belonging to that tree the selectionProperty associated value is true. The value is false for the other elements
TLP_SCOPE void tlp::selectSpanningForest |
( |
Graph * |
graph, |
|
|
BooleanProperty * |
selectionProperty, |
|
|
PluginProgress * |
pluginProgress = NULL |
|
) |
| |
Select a spanning forest of the graph, i.e for all graph elements (nodes or edges) belonging to that forest the selectionProperty associated value is true. The value is false for the other elements
TLP_SCOPE void tlp::selectSpanningTree |
( |
Graph * |
graph, |
|
|
BooleanProperty * |
selection, |
|
|
PluginProgress * |
pluginProgress = NULL |
|
) |
| |
Select a spanning tree of a graph assuming it is connected; i.e for all graph elements (nodes or edges) belonging to that tree the selectionProperty associated value is true. The value is false for the other elements
Variable Documentation
|