6 * $Date: 2012-07-02 20:59:27 +0200 (Mon, 02 Jul 2012) $
7 ***************************************************************/
10 * \brief Length attribute used in EmbedderMinDepthMaxFace.
11 * It contains two components (d, l) and a linear order is defined by:
12 * (d, l) > (d', l') iff d > d' or (d = d' and l > l')
14 * \author Thorsten Kerkhof
17 * This file is part of the Open Graph Drawing Framework (OGDF).
21 * See README.txt in the root directory of the OGDF installation for details.
24 * This program is free software; you can redistribute it and/or
25 * modify it under the terms of the GNU General Public License
26 * Version 2 or 3 as published by the Free Software Foundation;
27 * see the file LICENSE.txt included in the packaging of this file
31 * This program is distributed in the hope that it will be useful,
32 * but WITHOUT ANY WARRANTY; without even the implied warranty of
33 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
34 * GNU General Public License for more details.
37 * You should have received a copy of the GNU General Public
38 * License along with this program; if not, write to the Free
39 * Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
40 * Boston, MA 02110-1301, USA.
42 * \see http://www.gnu.org/copyleft/gpl.html
43 ***************************************************************/
49 #ifndef OGDF_EMBEDDER_MDMF_LENGTH_ATTRIBUTE_H
50 #define OGDF_EMBEDDER_MDMF_LENGTH_ATTRIBUTE_H
52 #include <ogdf/basic/basic.h>
56 class MDMFLengthAttribute
59 //constructors and destructor
60 MDMFLengthAttribute() { d
= l
= 0; }
61 MDMFLengthAttribute(const int& d
, const int& l
) : d(d
), l(l
) { }
62 MDMFLengthAttribute(const int& d
) : d(d
), l(0) { }
63 MDMFLengthAttribute(const MDMFLengthAttribute
& x
) : d(x
.d
), l(x
.l
) { }
64 ~MDMFLengthAttribute() { }
66 MDMFLengthAttribute
operator=(const MDMFLengthAttribute
& x
);
67 MDMFLengthAttribute
operator=(const int& x
);
68 bool operator==(const MDMFLengthAttribute
& x
);
69 bool operator!=(const MDMFLengthAttribute
& x
);
70 bool operator>(const MDMFLengthAttribute
& x
);
71 bool operator<(const MDMFLengthAttribute
& x
);
72 bool operator>=(const MDMFLengthAttribute
& x
);
73 bool operator<=(const MDMFLengthAttribute
& x
);
74 MDMFLengthAttribute
operator+(const MDMFLengthAttribute
& x
);
75 MDMFLengthAttribute
operator-(const MDMFLengthAttribute
& x
);
76 MDMFLengthAttribute
operator+=(const MDMFLengthAttribute
& x
);
77 MDMFLengthAttribute
operator-=(const MDMFLengthAttribute
& x
);
85 bool operator==(const MDMFLengthAttribute
& x
, const MDMFLengthAttribute
& y
);
86 bool operator!=(const MDMFLengthAttribute
& x
, const MDMFLengthAttribute
& y
);
87 bool operator>(const MDMFLengthAttribute
& x
, const MDMFLengthAttribute
& y
);
88 bool operator<(const MDMFLengthAttribute
& x
, const MDMFLengthAttribute
& y
);
89 bool operator>=(const MDMFLengthAttribute
& x
, const MDMFLengthAttribute
& y
);
90 bool operator<=(const MDMFLengthAttribute
& x
, const MDMFLengthAttribute
& y
);
91 MDMFLengthAttribute
operator+(const MDMFLengthAttribute
& x
, const MDMFLengthAttribute
& y
);
92 MDMFLengthAttribute
operator-(const MDMFLengthAttribute
& x
, const MDMFLengthAttribute
& y
);
93 MDMFLengthAttribute
operator+=(const MDMFLengthAttribute
& x
, const MDMFLengthAttribute
& y
);
94 MDMFLengthAttribute
operator-=(const MDMFLengthAttribute
& x
, const MDMFLengthAttribute
& y
);
95 ostream
& operator<<(ostream
& s
, const MDMFLengthAttribute
& x
);
97 } // end namespace ogdf