Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

CCLayoutPackModule.h
Go to the documentation of this file.
1 
33 #pragma once
34 
35 #include <ogdf/basic/Array.h>
36 #include <ogdf/basic/basic.h>
37 #include <ogdf/basic/geometry.h>
38 #include <ogdf/basic/memory.h>
39 
40 namespace ogdf {
41 
42 
50 public:
53 
54  virtual ~CCLayoutPackModule() { }
55 
71  virtual void call(Array<DPoint>& box, Array<DPoint>& offset, double pageRatio = 1.0) = 0;
72 
85  void operator()(Array<DPoint>& box, Array<DPoint>& offset, double pageRatio = 1.0) {
86  call(box, offset, pageRatio);
87  }
88 
104  virtual void call(Array<IPoint>& box, Array<IPoint>& offset, double pageRatio = 1.0) = 0;
105 
118  void operator()(Array<IPoint>& box, Array<IPoint>& offset, double pageRatio = 1.0) {
119  call(box, offset, pageRatio);
120  }
121 
130  static bool checkOffsets(const Array<DPoint>& box, const Array<DPoint>& offset);
131 
140  static bool checkOffsets(const Array<IPoint>& box, const Array<IPoint>& offset);
141 
142 
144 
145 private:
153  template<class POINT>
154  static bool checkOffsetsTP(const Array<POINT>& box, const Array<POINT>& offset);
155 };
156 
157 }
ogdf
The namespace for all OGDF objects.
Definition: multilevelmixer.cpp:39
geometry.h
Declaration of classes GenericPoint, GenericPolyline, GenericLine, GenericSegment,...
ogdf::CCLayoutPackModule
Base class of algorithms that arrange/pack layouts of connected components.
Definition: CCLayoutPackModule.h:49
OGDF_MALLOC_NEW_DELETE
#define OGDF_MALLOC_NEW_DELETE
Makes the class use malloc for memory allocation.
Definition: memory.h:92
ogdf::CCLayoutPackModule::CCLayoutPackModule
CCLayoutPackModule()
Initializes a layout packing module.
Definition: CCLayoutPackModule.h:52
ogdf::Array
The parameterized class Array implements dynamic arrays of type E.
Definition: Array.h:219
ogdf::CCLayoutPackModule::operator()
void operator()(Array< DPoint > &box, Array< DPoint > &offset, double pageRatio=1.0)
Arranges the rectangles given by box.
Definition: CCLayoutPackModule.h:85
ogdf::CCLayoutPackModule::operator()
void operator()(Array< IPoint > &box, Array< IPoint > &offset, double pageRatio=1.0)
Arranges the rectangles given by box.
Definition: CCLayoutPackModule.h:118
basic.h
Basic declarations, included by all source files.
OGDF_EXPORT
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF DLL.
Definition: config.h:101
Array.h
Declaration and implementation of Array class and Array algorithms.
ogdf::CCLayoutPackModule::~CCLayoutPackModule
virtual ~CCLayoutPackModule()
Definition: CCLayoutPackModule.h:54
memory.h
Declaration of memory manager for allocating small pieces of memory.