# Hurricane VLSI Database

Vertical.h
1 // ****************************************************************************************************
2 // File: ./hurricane/Vertical.h
3 // Authors: R. Escassut
4 // Copyright (c) BULL S.A. 2000-2018, All Rights Reserved
5 //
6 // This file is part of Hurricane.
7 //
8 // Hurricane is free software: you can redistribute it and/or modify it under the terms of the GNU
9 // Lesser General Public License as published by the Free Software Foundation, either version 3 of the
10 // License, or (at your option) any later version.
11 //
12 // Hurricane is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even
13 // the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the Lesser GNU
14 // General Public License for more details.
15 //
16 // You should have received a copy of the Lesser GNU General Public License along with Hurricane. If
17 // not, see <http://www.gnu.org/licenses/>.
18 // ****************************************************************************************************
19
20 #ifndef HURRICANE_VERTICAL
21 #define HURRICANE_VERTICAL
22
23 #include "hurricane/Segment.h"
24 #include "hurricane/Verticals.h"
25
26 namespace Hurricane {
27
28
29 class Layer;
30
31
32 // ****************************************************************************************************
33 // Vertical declaration
34 // ****************************************************************************************************
35
36 class Vertical : public Segment {
37 // ****************************
38
39 // Types
40 // *****
41
42 public: typedef Segment Inherit;
43
44 // Attributes
45 // **********
46
47 private: DbU::Unit _x;
48 private: DbU::Unit _dySource;
49 private: DbU::Unit _dyTarget;
50
51 // Constructors
52 // ************
53
54 protected: Vertical ( Net* net
55 , Component* source
56 , Component* target
57 , const Layer* layer
58 , const DbU::Unit& x
59 , const DbU::Unit& width = 0
60 , const DbU::Unit& dySource = 0
61 , const DbU::Unit& dyTarget = 0
62 );
63
64 public: static Vertical* create ( Net* net
65 , const Layer* layer
66 , const DbU::Unit& x
67 , const DbU::Unit& width = 0
68 , const DbU::Unit& dySource = 0
69 , const DbU::Unit& dyTarget = 0
70 );
71 public: static Vertical* create ( Component* source
72 , Component* target
73 , const Layer* layer
74 , const DbU::Unit& x
75 , const DbU::Unit& width = 0
76 , const DbU::Unit& dySource = 0
77 , const DbU::Unit& dyTarget = 0
78 );
79
80 // Accessors
81 // *********
82
83 public: virtual DbU::Unit getX() const {return _x;};
84 public: virtual Point getCenter() const;
85 public: virtual Box getBoundingBox() const;
86 public: virtual Box getBoundingBox(const BasicLayer* basicLayer) const;
87 public: virtual DbU::Unit getSourceX() const {return getX();};
88 public: virtual DbU::Unit getSourceY() const;
89 public: virtual DbU::Unit getTargetX() const {return getX();};
90 public: virtual DbU::Unit getTargetY() const;
91 public: virtual DbU::Unit getLength() const;
92 public: const DbU::Unit& getDySource() const {return _dySource;};
93 public: const DbU::Unit& getDyTarget() const {return _dyTarget;};
94
95 // Updators
96 // ********
97
98 public: virtual void translate(const DbU::Unit& dx, const DbU::Unit& dy);
99
100 public: void setX(const DbU::Unit& x);
101 public: void setDySource(const DbU::Unit& dySource);
102 public: void setDyTarget(const DbU::Unit& dyTarget);
103 public: void translate(const DbU::Unit& dx);
104
105 // Others
106 // ******
107
108 public: virtual void _toJson(JsonWriter*) const;
109 public: static JsonObject* getJsonObject(unsigned long flags);
110 public: virtual string _getTypeName() const {return _TName("Vertical");};
111 public: virtual string _getString() const;
112 public: virtual Record* _getRecord() const;
113
114 };
115
116
117 class JsonVertical : public JsonSegment {
118 // **************************************
119
120 public: static void initialize();
121 public: JsonVertical(unsigned long flags);
122 public: virtual string getTypeName() const;
123 public: virtual JsonVertical* clone(unsigned long) const;
124 public: virtual void toData(JsonStack&);
125 };
126
127 } // End of Hurricane namespace.
128
129
130 INSPECTOR_P_SUPPORT(Hurricane::Vertical);
131
132
133 #endif // HURRICANE_VERTICAL
134
135
136 // ****************************************************************************************************
137 // Copyright (c) BULL S.A. 2000-2018, All Rights Reserved
138 // ****************************************************************************************************
Hurricane::BasicLayer
BasicLayer description (API)
Definition: BasicLayer.h:44
Hurricane::Component
Component description (API)
Definition: Component.h:42
Hurricane::Vertical::getDySource
const DbU::Unit & getDySource() const
Definition: Vertical.h:92
Hurricane::JsonObject
Support for JSON export.
Definition: JsonObject.h:83
Hurricane::Vertical::Inherit
Segment Inherit
Definition: Vertical.h:42
Hurricane::DbU::Unit
std::int64_t Unit
Definition: DbU.h:70
Hurricane::Point
Point description (API)
Definition: Point.h:32
Hurricane::Vertical
Vertical description (API)
Definition: Vertical.h:36
Hurricane::Box
Box description (API)
Definition: Box.h:31
Hurricane::Vertical::setX
void setX(const DbU::Unit &x)
Hurricane::Layer
Layer description (API)
Definition: Layer.h:52
Hurricane::Segment
Segment description (API)
Definition: Segment.h:33
Hurricane
The namespace dedicated to Hurricane.
Definition: Generalities.dox:5
Hurricane::Net
Net description (API)
Definition: Net.h:48
Hurricane::Vertical::create
static Vertical * create(Net *net, const Layer *layer, const DbU::Unit &x, const DbU::Unit &width=0, const DbU::Unit &dySource=0, const DbU::Unit &dyTarget=0)
Hurricane::Vertical::getDyTarget
const DbU::Unit & getDyTarget() const
Definition: Vertical.h:93

Generated by doxygen 1.8.14 on Tue Jul 21 2020 | Return to top of page

Hurricane VLSI Database | Copyright © 2000-2016 Bull S.A. All rights reserved