Overview     Modules     Class Hierarchy     Classes     Members  

tlp Namespace Reference


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.

Classes

Typedefs

Enumerations

Functions

Variables


Typedef Documentation

typedef AbstractProperty<ColorType, ColorType, ColorAlgorithm> tlp::AbstractColorProperty
 

typedef AbstractProperty<DoubleType, DoubleType, DoubleAlgorithm> tlp::AbstractDoubleProperty
 

typedef AbstractProperty<IntegerType,IntegerType, IntegerAlgorithm> tlp::AbstractIntegerProperty
 

typedef AbstractProperty<PointType, LineType, LayoutAlgorithm> tlp::AbstractLayoutProperty
 

typedef AbstractProperty<SizeType,SizeType, SizeAlgorithm> tlp::AbstractSizeProperty
 

typedef AbstractProperty<StringType,StringType, StringAlgorithm> tlp::AbstractStringProperty
 

typedef std::map<Observable *,std::set<Observer *> > tlp::ObservableMap
 

typedef std::map<Observer *,std::set<Observable *> > tlp::ObserverMap
 


Enumeration Type Documentation

enum tlp::EDGE_TYPE
 

Enumerator:
DIRECTED 
INV_DIRECTED 
UNDIRECTED 

enum tlp::ElementType
 

Enumerator:
NODE 
EDGE 

enum tlp::ProgressState
 

Enumerator:
TLP_CONTINUE 
TLP_CANCEL 
TLP_STOP 

enum tlp::State
 

Enumerator:
VECT 
HASH 


Function Documentation

TLP_SCOPE bool tlp::applyAlgorithm Graph *  graph,
std::string &  errorMsg,
DataSet *  dataSet = 0,
const std::string &  alg = "any",
PluginProgress *  plugProgress = 0
 

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 lengh 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 = UINT_MAX,
PluginProgress *  = NULL
 

TLP_SCOPE BoundingBox tlp::computeBoundingBox const Graph *  graph,
const LayoutProperty *  layout,
const SizeProperty *  size,
const DoubleProperty *  rotation,
const BooleanProperty *  selection = 0
 

Compute the bounding box of a graph according to node position edge bends node z-rotation, and size of elements

TLP_SCOPE std::pair<Coord, Coord> tlp::computeBoundingRadius const Graph *  graph,
const LayoutProperty *  layout,
const SizeProperty *  size,
const DoubleProperty *  rotation,
const BooleanProperty *  selection = 0
 

Compute a bounding sphere of a graph according to node position edge bends node z-rotation, and size of elements

Todo:
make that fucntion return a new type of class called BoundingSphere

test if that function correctly compute a bounding sphere.

TLP_SCOPE std::vector<std::vector<node> > tlp::computeCanonicalOrdering PlanarConMap *  ,
std::vector< edge > *  dummyEdges = 0,
PluginProgress *  pluginProgress = 0
 

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 = 0
 

Compute a convexHull of a graph according to node position edge bends node z-rotation, and size of elements. Only works in 2D.

Todo:
refactor code from GlConvexHull here

TLP_SCOPE bool tlp::computeEqualValueClustering Graph *  graph,
PropertyInterface *  property,
bool  onNodes = true,
PluginProgress *  pluginProgress = 0
 

Compute the subgraphs whose elements have the same value for property This one is an obsolete version (should be remove in 3.1); use the previous one

TLP_SCOPE bool tlp::computeEqualValueClustering Graph *  graph,
PropertyInterface *  property,
bool  onNodes = true,
bool  connected = false,
PluginProgress *  pluginProgress = 0
 

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.

TLP_SCOPE void tlp::copyToGraph Graph *  outG,
Graph *  inG,
BooleanProperty *  inSelection = 0,
BooleanProperty *  outSelection = 0
 

Append the selected part of the graph inG (properties, nodes & 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
 

template<typename TYPE>
TYPE tlp::defaultTypeValue  )  [inline]
 

TLP_SCOPE std::string tlp::demangleTlpClassName const char *  className  ) 
 

returns the demangled name of a C++ class defines in the tlp namespace. The tlp:: prefix is omitted and the returned pointer do not have to be deallocated.

TLP_SCOPE bool tlp::exportGraph Graph *  graph,
std::ostream &  os,
const std::string &  alg,
DataSet &  dataSet,
PluginProgress *  plugProgress = 0
 

TLP_SCOPE std::istream* tlp::getIgzstream const char *  name,
int  open_mode = std::ios::in
 

TLP_SCOPE std::string tlp::getMajor const std::string &  release  ) 
 

Extracts Major number from a release number

TLP_SCOPE std::string tlp::getMinor const std::string &  release  ) 
 

Extracts Minor number from a release number

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()!

TLP_SCOPE bool tlp::getSource Graph *  ,
node &  n
 

find the first node of degree 0, if no node exist return false else true

TLP_SCOPE node tlp::graphCenterHeuristic Graph *  graph  ) 
 

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 &  alg,
DataSet &  dataSet,
PluginProgress *  plugProgress = 0,
Graph *  newGraph = 0
 

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 char *  appDirPath = 0  ) 
 

TLP_SCOPE Graph* tlp::loadGraph const std::string &  filename  ) 
 

Load a graph in the tlp format Warning : this function use "tlp" import plugin (must be laoded)

TLP_SCOPE bool tlp::loadPlugin const std::string &  filename,
PluginLoader *  plug = 0
 

TLP_SCOPE void tlp::loadPlugins PluginLoader *  plug = 0  ) 
 

TLP_SCOPE void tlp::loadPluginsCheckDependencies PluginLoader *  loader = 0  ) 
 

TLP_SCOPE void tlp::loadPluginsFromDir std::string  dir,
std::string  type,
PluginLoader *  loader = 0
 

TLP_SCOPE void tlp::makeProperDag Graph *  graph,
std::list< node > &  addedNodes,
TLP_HASH_MAP< edge, edge > &  replacedEdges,
IntegerProperty *  edgeLength = 0
 

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 *   ) 
 

TLP_SCOPE unsigned int tlp::maxDistance const Graph *  graph,
const node  n,
MutableContainer< unsigned int > &  distance,
EDGE_TYPE  direction = UNDIRECTED
 

TLP_SCOPE unsigned int tlp::minDegree const Graph *   ) 
 

TLP_SCOPE Graph* tlp::newCloneSubGraph Graph *  ,
std::string  name = "unnamed"
 

Return a subgraph equal to the graph given in parameter (a clone subgraph)

TLP_SCOPE Graph* tlp::newGraph  ) 
 

Returns a new graph

TLP_SCOPE Graph* tlp::newSubGraph Graph *  ,
std::string  name = "unnamed"
 

Return an empty 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
 

TLP_SCOPE void tlp::removeFromGraph Graph *  ioG,
BooleanProperty *  inSelection = 0
 

Remove the selected part of the graph ioG (properties, nodes & 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 *  ,
const std::string &  filename
 

Save a graph in tlp format Warning : this function use "tlp" export plugin (must be laoded)

TLP_SCOPE void tlp::selectMinimumSpanningTree Graph *  graph,
BooleanProperty *  selectionProperty,
DoubleProperty *  weight = 0,
PluginProgress *  pluginProgress = 0
 

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 = 0
 

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


Variable Documentation

TLP_SCOPE const char tlp::PATH_DELIMITER
 

TLP_SCOPE std::string tlp::TulipBitmapDir
 

TLP_SCOPE std::string tlp::TulipDocProfile
 

TLP_SCOPE std::string tlp::TulipLibDir
 

TLP_SCOPE std::string tlp::TulipPluginsPath
 

TLP_SCOPE std::string tlp::TulipUserHandBookIndex
 



Tulip Software by LaBRI Visualization Team    2001 - 2010