HierarchicalLayoutTypedefs.h 2.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. #ifndef HIERARCHICALLAYOUTTYPEDEFS_H
  2. #define HIERARCHICALLAYOUTTYPEDEFS_H
  3. #include <QMap>
  4. #include <Common/GraphType.h>
  5. #include <QQueue>
  6. #include <HierarchicalLayoutGenerator/NestingTreeSubgraphNode.h>
  7. #include <HierarchicalLayoutGenerator/LayerNode.h>
  8. #include <HierarchicalLayoutGenerator/ReducedNestingTreeNode.h>
  9. /*! Layer Data structure:
  10. * It can access graph hierararchy horizontally
  11. */
  12. //This map can be used to map horizontal position of vertex to the vertex descriptor
  13. typedef QMap<std::size_t , VertexDescriptor> MapPositionToVertexDescriptor;
  14. /*! Iterator type for MapPositionToVertexDescriptor */
  15. typedef QMapIterator<std::size_t , VertexDescriptor> IteratorMapPositionToVertexDescriptor;
  16. /*! This map is used to list and access LayerNodes of vertices having same rank
  17. by their relative position(int) within that layer */
  18. typedef QMap<double , LayerNode*> MapPositionToLayerNode;
  19. typedef QMapIterator<double , LayerNode*> IteratorMapPositionToLayerNode; /*!< Iterator type for LayerNodes at Layer that is MapPositionToLayerNode >*/
  20. typedef QMultiMap<double , LayerNode*> MultiMapBarryCenterToLayerNode; /*!< This is a multimap, key is barry center and value is corresponding LayerNode >*/
  21. typedef QMapIterator<double , LayerNode*> IteratorMultiMapBarryCenterToLayerNode; /*!< Iterator type for LayerNodes of MultiMapBarryCenterToLayerNode >*/
  22. /*! Layers map: This map is used to list and access LayerNodes by their levels */
  23. typedef QMap<int , MapPositionToLayerNode*> MapLayerIdToLayerRef;
  24. /*! Iterator type for Layers that is MapLayerIdToLayerRef */
  25. typedef QMapIterator<int , MapPositionToLayerNode*> IteratorMapLayerIdToLayerRef;
  26. /*! Map of Reduced Nesting trees for every layer
  27. */
  28. typedef QMap<int , ReducedNestingTreeNode*> MapLayerIdtoReducedNestedTreeRef;
  29. typedef QQueue<NestingTreeSubgraphNode*> QueueNestingTreeSubgraphNodesRef;
  30. /*! Direction Enum - Used for specifying top-down or bottom-up directions
  31. * in crossing reduction functions
  32. */
  33. enum ProcessDirection { UpDirection = 2000 , DownDirection = 2001 };
  34. enum NeighborNodes { Succesor = 2005 , Predecessor = 2006 }; /*!< Neighbour nodes enum >*/
  35. enum LayerType { GraphVerticesLayer = 2500 , BorderVerticesLayer = 2501 , AnyTypeLayer = 2502}; /*!< Layer type enum >*/
  36. #endif // HIERARCHICALLAYOUTTYPEDEFS_H