torc-master
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
NetlistInstance.hpp
Go to the documentation of this file.
1 // Torc - Copyright 2011-2013 University of Southern California. All Rights Reserved.
2 // $HeadURL$
3 // $Id$
4 
5 // This program is free software: you can redistribute it and/or modify it under the terms of the
6 // GNU General Public License as published by the Free Software Foundation, either version 3 of the
7 // License, or (at your option) any later version.
8 //
9 // This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
10 // without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See
11 // the GNU General Public License for more details.
12 //
13 // You should have received a copy of the GNU General Public License along with this program. If
14 // not, see <http://www.gnu.org/licenses/>.
15 
16 #ifndef TORC_PLACER_NETLISTINSTANCE_HPP
17 #define TORC_PLACER_NETLISTINSTANCE_HPP
18 
22 #include <vector>
23 
24 namespace torc {
25 namespace placer {
26  class DeviceSite;
27 
29  //types
30  typedef boost::uint32_t uint32;
32 
33  protected:
34  DeviceSite* mSite; // this is the site on which this instance is placed
35 
37  uint32 mInstanceType; // the type index for sites that this instance can be placed on
38  // type indexes
39  //std::vector<int> m
40 
41  public:
42  NetlistInstance(InstanceSharedPtr inInstance, uint32 inType) : mSite(NULL),
43  mPhysicalInstance(inInstance), mInstanceType(inType) {}
45  void setSite(DeviceSite* siteptr) {
46  mSite = siteptr;
47  }
49  return mSite;
50  }
52  return mPhysicalInstance;
53  }
55  return mInstanceType;
56  }
57  void addPin(NetlistPin* pin) {
58  }
60  return 0;
61  }
63  return 0;
64  }
65  }; // class NetlistInstance
66 
67  typedef std::vector<NetlistInstance*> NetlistInstancePtrVector;
68 } // namespace placer
69 } // namespace torc
70 #endif // TORC_PLACER_NETLISTINSTANCE_HPP
NetlistInstance(InstanceSharedPtr inInstance, uint32 inType)
Header for the Instance class.
std::vector< NetlistInstance * > NetlistInstancePtrVector
void setSite(DeviceSite *siteptr)
InstanceSharedPtr getInstance()
boost::shared_ptr< Instance > InstanceSharedPtr
Shared pointer encapsulation of an Instance.
void addPin(NetlistPin *pin)
NetlistPin * getPin(uint32 index)
InstanceSharedPtr mPhysicalInstance
physical::InstanceSharedPtr InstanceSharedPtr