21 #include <boost/bind.hpp>
22 #include <boost/mem_fn.hpp>
23 #ifdef GENOM_SERIALIZATION
24 #include <boost/archive/binary_iarchive.hpp>
25 #include <boost/archive/binary_oarchive.hpp>
26 #include <boost/serialization/base_object.hpp>
27 #include <boost/serialization/export.hpp>
28 #endif //GENOM_SERIALIZATION
34 #ifdef GENOM_SERIALIZATION
36 #endif //GENOM_SERIALIZATION
61 if(inNet->getSize() != getSize()) {
77 for(; childPort != childEnd; ++childPort, ++net) {
79 (*childPort)->connect(*net);
127 for(; childPort != childEnd; ++childPort, ++net) {
129 (*childPort)->disconnect(*net);
161 create(newPortBundle);
162 newPortBundle->setName(inName);
163 newPortBundle->setOriginalName(inOriginalName);
164 if(inParentCollection) {
165 inParentCollection->addChild(newPortBundle);
167 inViewPtr->addPort(newPortBundle);
169 return newPortBundle;
191 #ifdef GENOM_SERIALIZATION
192 template <
class Archive>
void PortBundle::serialize(Archive& ar,
unsigned int) {
193 ar & boost::serialization::base_object< Port >(*this);
194 ar & boost::serialization::base_object< Bundle<Port> >(*this);
198 template void PortBundle::serialize<boost::archive::binary_iarchive>(
199 boost::archive::binary_iarchive& ar,
const unsigned int);
201 template void PortBundle::serialize<boost::archive::binary_oarchive>(
202 boost::archive::binary_oarchive& ar,
const unsigned int);
204 #endif //GENOM_SERIALIZATION
virtual Connection connect(const NetSharedPtr &inNet)=0
void log(const char *fmt,...)
virtual void accept(BaseVisitor &inoutVisitor)
Represents a bundle of ports.
virtual void setParent(const ViewSharedPtr &inParent)
void disconnectPortFromNet(const PortSharedPtr &inPort)
boost::shared_ptr< PortBundle > PortBundleSharedPtr
std::list< NetSharedPtr >::iterator Connection
virtual Connectable::Connection connect(const NetSharedPtr &inNet)
void runVisitor(_Tp &inoutVisited, BaseVisitor &inoutVisitor)
virtual void disconnect()
void connectPortToNet(const PortSharedPtr &inPort)
The Error object thrown by different methods of EdifOM.
boost::shared_ptr< Net > NetSharedPtr
A base class for Visitor.
const boost::shared_ptr< View > getParent() const
void saveContextData(const std::string &inName, const boost::any &inSource)
void applyOnAllChildren(const _Action &action)
void getChildren(typename Bundle< _BaseType >::List &outChildren) const
virtual PortBundleSharedPtr newPortBundlePtr(const std::string &inName, const ViewSharedPtr &inViewPtr, const PortBundleSharedPtr &inParentCollection=PortBundleSharedPtr(), const std::string &inOriginalName=std::string())
virtual void getChildren(List &outChildren) const
Interface for an EDIF port object.
boost::shared_ptr< View > ViewSharedPtr
virtual void setParent(const boost::shared_ptr< _ParentType > &inSource)
Represents a "bundle" in the EDIF sense.
Flatten a bundle to bits.
void setCurrentLocation(const std::string &inFunction, const std::string &inFile, uint32_t inLine)