torc-master
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
torc::generic::VectorNetBit Class Referenceabstract

Represents a bit of a net array. More...

#include <VectorNetBit.hpp>

+ Inheritance diagram for torc::generic::VectorNetBit:
+ Collaboration diagram for torc::generic::VectorNetBit:

Public Types

typedef FactoryType< VectorNetBitFactory
 
typedef VisitorType< VectorNetBitVisitor
 
typedef std::list
< NetSharedPtr >::iterator 
Connection
 
typedef
boost::signals2::signal< void(const
NetSharedPtr &)> 
Connected
 
typedef
boost::signals2::signal< void(const
NetSharedPtr &)> 
Disconnected
 
typedef std::string Name
 
typedef Net Type
 
typedef boost::shared_ptr< TypePointer
 
typedef boost::weak_ptr< TypeWeakPointer
 
typedef std::vector< PointerList
 
typedef size_t SizeType
 
typedef Net Type
 
typedef Composite< TypeBaseType
 
typedef BaseType::List List
 
typedef BaseType::Pointer Pointer
 
typedef BaseType::SizeType SizeType
 

Public Member Functions

virtual void accept (BaseVisitor &inoutVisitor) throw (Error)
 
virtual Connection connect (const NetSharedPtr &inNet) throw (Error)
 
virtual void disconnect (const Connection &inConnection) throw (Error)
 
virtual void getConnectedNets (std::vector< NetSharedPtr > &outNets, bool inSkipChildConnections=false) const throw (Error)
 
virtual void getConnectedPorts (std::vector< PortSharedPtr > &outPorts, bool inSkipChildConnections=false) const
 
virtual void getConnectedPortRefs (std::vector< PortReferenceSharedPtr > &outPortRefs, bool inSkipChildConnections=false) const
 
 VectorNetBit ()
 
virtual ~VectorNetBit () throw ()
 
void addSubnet (const NetSharedPtr &inSubnet) throw (Error)
 
NetSharedPtr findSubnet (const std::string &inName) throw (Error)
 
void removeSubnet (const std::string &inName) throw (Error)
 
void getSubnets (std::vector< NetSharedPtr > &outSubnets) const
 
void setSubnets (const std::vector< NetSharedPtr > &inSource) throw (Error)
 
template<typename _Action >
void applyOnAllSubnets (const _Action &action) throw (Error)
 
NetSharedPtr getParentNet () const
 
void setParentNet (const NetSharedPtr &inParent)
 
const NetAttributesSharedPtr getAttributes () const
 
void setAttributes (const NetAttributesSharedPtr &inSource)
 
PortSharedPtr findConnectedPort (const std::string &inName) throw (Error)
 
template<typename _Action >
void applyOnAllConnectedPorts (const _Action &action) throw (Error)
 
virtual void getConnectedPortLists (std::vector< PortListSharedPtr > &outPortList) const
 
template<typename _Action >
void applyOnAllConnectedPortLists (const _Action &action) throw (Error)
 
virtual void disconnect () throw (Error)
 
void disconnect (const std::string &inName) throw (Error)
 
void disconnect (const NetSharedPtr &net) throw (Error)
 
PortReferenceSharedPtr findConnectedPortReference (const std::string &inName) throw (Error)
 
template<typename _Action >
void applyOnAllConnectedPortRefs (const _Action &action) throw (Error)
 
void addComment (const std::string &comment)
 
const std::vector< std::string > & getComments () const
 
void setComments (const std::vector< std::string > &inSource)
 
ConnectedsignalNetConnected ()
 
DisconnectedsignalNetDisconnected ()
 
virtual const std::string getName () const
 
void setName (const std::string &inSource) throw (Error)
 
PropertySharedPtr getProperty (const std::string &inName)
 
bool setProperty (const std::string &inName, const PropertySharedPtr &inProperty)
 
void getProperties (std::map< std::string, PropertySharedPtr > &outProperties) const
 
void setProperties (const std::map< std::string, PropertySharedPtr > &inSource)
 
template<typename _Action >
void applyOnAllProperties (const _Action &action) throw (Error)
 
virtual Name getOriginalName () const
 
virtual void setOriginalName (const Name &inSource)
 
virtual CompositionType getCompositionType () const =0
 
virtual size_t getSize () const =0
 
virtual void getChildren (List &outChildren) const =0 throw (Error)
 
virtual const Pointer get (const std::vector< SizeType > &inIndices) const =0 throw (Error)
 
virtual void setParentCollection (const Pointer &inParentCollection)
 
virtual Pointer getParentCollection () const
 
void setWeakThis (const WeakPointer &inWeakThis)
 
Pointer getSharedThis () const
 
const boost::shared_ptr< ViewgetParent () const
 
virtual void setParent (const boost::shared_ptr< View > &inSource)
 
void getUserData (std::list< std::string > &outUserData) const
 
void setUserData (const std::list< std::string > &inSource)
 
void addUserData (const std::string &inSource)
 
virtual CompositionType getCompositionType () const
 
virtual SizeType getSize () const
 
virtual void getChildren (List &outChildren) const throw (Error)
 
virtual const Pointer get (const std::vector< SizeType > &inIndices) const throw (Error)
 
const std::vector< SizeType > & getIndices () const
 
void setIndices (const std::vector< SizeType > &inSource)
 
SizeType getAbsoluteIndex () const
 
void setAbsoluteIndex (SizeType inSource)
 

Protected Member Functions

void addConnectedPort (const PortSharedPtr &inPort) throw (Error)
 
void removeConnectedPort (const PortSharedPtr &inPort) throw (Error)
 
void addConnectedPortList (const PortListSharedPtr &inPort) throw (Error)
 
void removeConnectedPortList (const PortListSharedPtr &inList) throw (Error)
 
void setConnectedPorts (const std::vector< PortSharedPtr > &inSource) throw (Error)
 
void addConnectedPortReference (const PortReferenceSharedPtr &portRef) throw (Error)
 
void removeConnectedPortReference (const PortReferenceSharedPtr &inPortRef) throw (Error)
 
void setConnectedPortRefs (const std::vector< PortReferenceSharedPtr > &inSource) throw (Error)
 
virtual void onConnect () throw (Error)
 
virtual void onDisconnect () throw (Error)
 

Detailed Description

Represents a bit of a net array.

The VectorNetBit class represents a bit of an array net. Such objects cannot be created in EDIF. They are automatically created when a particular member of an array is accessed using the (member ...) syntax.

Definition at line 43 of file VectorNetBit.hpp.

Member Typedef Documentation

Definition at line 47 of file VectorBit.hpp.

typedef boost::signals2::signal<void(const NetSharedPtr&)> torc::generic::Connectable::Connected
inherited

A signal to indicate that a new connection has been made

Definition at line 57 of file Connectable.hpp.

typedef std::list<NetSharedPtr>::iterator torc::generic::Connectable::Connection
inherited

A connection between a net and this object

Definition at line 52 of file Connectable.hpp.

typedef boost::signals2::signal<void(const NetSharedPtr&)> torc::generic::Connectable::Disconnected
inherited

A signal to indicate that a connection has been removed

Definition at line 62 of file Connectable.hpp.

Definition at line 48 of file VectorBit.hpp.

typedef std::vector<Pointer> torc::generic::Composite< Net >::List
inherited

List of Shared Pointers to objects of type Type

Definition at line 61 of file Composite.hpp.

typedef std::string torc::generic::Renamable::Name
inherited

Definition at line 40 of file generic/Renamable.hpp.

Definition at line 49 of file VectorBit.hpp.

typedef boost::shared_ptr<Type> torc::generic::Composite< Net >::Pointer
inherited

Shared Pointer to object of type Type

Definition at line 55 of file Composite.hpp.

Definition at line 50 of file VectorBit.hpp.

typedef size_t torc::generic::Composite< Net >::SizeType
inherited

Definition at line 62 of file Composite.hpp.

typedef Net torc::generic::VectorBit< Net >::Type
inherited

Definition at line 46 of file VectorBit.hpp.

typedef Net torc::generic::Composite< Net >::Type
inherited

Definition at line 50 of file Composite.hpp.

typedef boost::weak_ptr<Type> torc::generic::Composite< Net >::WeakPointer
inherited

Definition at line 56 of file Composite.hpp.

Constructor & Destructor Documentation

torc::generic::VectorNetBit::VectorNetBit ( )

Definition at line 211 of file VectorNetBit.cpp.

211 : Net(), VectorBit<Net>() {}
torc::generic::VectorNetBit::~VectorNetBit ( )
throw (
)
virtual

Definition at line 213 of file VectorNetBit.cpp.

213 {}

Member Function Documentation

void torc::generic::VectorNetBit::accept ( BaseVisitor inoutVisitor)
throw (Error
)
virtual

Implements torc::generic::Visitable.

Definition at line 38 of file VectorNetBit.cpp.

38  {
39  try {
40  runVisitor(*this, inoutVisitor);
41  } catch(Error& e) {
42  e.setCurrentLocation(__FUNCTION__, __FILE__, __LINE__);
43  throw;
44  }
45 }
void runVisitor(_Tp &inoutVisited, BaseVisitor &inoutVisitor)
Definition: VisitorType.hpp:78

+ Here is the call graph for this function:

void torc::generic::Commentable::addComment ( const std::string &  comment)
inherited

Add a comment to the object

Parameters
[in]commentThe comment to add to an existing list of comments

Definition at line 36 of file Commentable.cpp.

36  {
37  mComments.push_back(comment);
38 }
std::vector< std::string > mComments
Definition: Commentable.hpp:77
void torc::generic::Net::addConnectedPort ( const PortSharedPtr inPort)
throw (Error
)
protectedinherited

Connect a port to this net.

Parameters
[in]inPortport to be added. Empty pointer is ignored.
Exceptions
ErrorCould not add Port, because Port name is empty
ErrorCould not add Port, because Port name is already exists

Definition at line 147 of file generic/Net.cpp.

147  {
148  if(!inPort) {
149  return;
150  }
151  std::string name = inPort->getName();
152  if(name.empty()) {
153  Error e(eMessageIdErrorEmptyItemName, __FUNCTION__, __FILE__, __LINE__);
154  e.saveContextData("Port name", name);
155  throw e;
156  }
157  mConnectedPorts.push_back(inPort);
158  return;
159 }
std::list< PortSharedPtr > mConnectedPorts
std::string string

+ Here is the call graph for this function:

void torc::generic::Net::addConnectedPortList ( const PortListSharedPtr inPort)
throw (Error
)
protectedinherited

Definition at line 218 of file generic/Net.cpp.

218  {
219  if(!inPortList) {
220  return;
221  }
222  mConnectedPortLists.push_back(inPortList);
223  return;
224 }
std::list< PortListSharedPtr > mConnectedPortLists
void torc::generic::Net::addConnectedPortReference ( const PortReferenceSharedPtr inPortRef)
throw (Error
)
protectedinherited

Connect a port reference to this net.

Parameters
[in]inPortRefPort reference to be added
Exceptions
ErrorCould not add port reference

Definition at line 247 of file generic/Net.cpp.

247  {
248  if(!inPortRef) {
249  return;
250  }
251  std::string name = inPortRef->getName();
252  if(name.empty()) {
253  Error e(eMessageIdErrorEmptyItemName, __FUNCTION__, __FILE__, __LINE__);
254  e.saveContextData("PortReference name", name);
255  throw e;
256  }
257  mConnectedPortRefs.push_back(inPortRef);
258  return;
259 }
std::list< PortReferenceSharedPtr > mConnectedPortRefs
std::string string

+ Here is the call graph for this function:

void torc::generic::Net::addSubnet ( const NetSharedPtr inSubnet)
throw (Error
)
inherited

Add a subnet to this net.

Parameters
[in]inSubnetSubnet to be added
Exceptions
ErrorCould not add subnet, because subnet name is empty
  • Id : eMessageIdErrorEmptyItemName
  • Context Data
    • Subnet name - String
ErrorCould not add subnet, because subnet name is already exists
  • Id : eMessageIdErrorItemAlreadyExists
  • Context Data
    • Subnet name - String

Add a subnet to this net.

Parameters
[in]inSubnetSubnet to be added
Exceptions
ErrorCould not add subnet, because subnet name is empty
ErrorCould not add subnet, because subnet name is already exists

Definition at line 63 of file generic/Net.cpp.

63  {
64  std::string name = inSubnet->getName();
65  if(name.empty()) {
66  Error e(eMessageIdErrorEmptyItemName, __FUNCTION__, __FILE__, __LINE__);
67  e.saveContextData("Subnet name", name);
68  throw e;
69  }
70  if(false == mSubnets.set(name, inSubnet)) {
71  Error e(eMessageIdErrorItemAlreadyExists, __FUNCTION__, __FILE__, __LINE__);
72  e.saveContextData("Subnet name", name);
73  throw e;
74  }
75  inSubnet->setParentNet(getSharedThis());
76  return;
77 }
bool set(const KeyType &inKey, const ValueType &inValue)
Definition: SymTab.hpp:132
std::string string
SymTab< std::string, NetSharedPtr, true > mSubnets

+ Here is the call graph for this function:

void torc::generic::UserDataContainer::addUserData ( const std::string &  inSource)
inherited

Add an user data to the list of user data

Parameters
[in]inSourceAn user data as string

Definition at line 34 of file UserDataContainer.cpp.

34  {
35  mUserData.push_back(inSource);
36 }
std::list< std::string > mUserData
template<typename _Action >
void torc::generic::Net::applyOnAllConnectedPortLists ( const _Action &  action)
throw (Error
)
inlineinherited

Apply action on all connected port lists.

Parameters
[in]actionAction to be applied

Definition at line 317 of file generic/Net.hpp.

318  {
319  try {
320  std::for_each(mConnectedPortLists.begin(), mConnectedPortLists.end(), action);
321  } catch(Error& e) {
322  e.setCurrentLocation(__FUNCTION__, __FILE__, __LINE__);
323  throw;
324  }
325 }
std::list< PortListSharedPtr > mConnectedPortLists

+ Here is the call graph for this function:

template<typename _Action >
void torc::generic::Net::applyOnAllConnectedPortRefs ( const _Action &  action)
throw (Error
)
inlineinherited

Apply action on all connected port refs.

Parameters
[in]actionAction to be applied

Definition at line 327 of file generic/Net.hpp.

328  {
329  try {
330  std::for_each(mConnectedPortRefs.begin(), mConnectedPortRefs.end(), action);
331  } catch(Error& e) {
332  e.setCurrentLocation(__FUNCTION__, __FILE__, __LINE__);
333  throw;
334  }
335 }
std::list< PortReferenceSharedPtr > mConnectedPortRefs

+ Here is the call graph for this function:

template<typename _Action >
void torc::generic::Net::applyOnAllConnectedPorts ( const _Action &  action)
throw (Error
)
inlineinherited

Apply action on all connected ports.

Parameters
[in]actionAction to be applied

Definition at line 307 of file generic/Net.hpp.

308  {
309  try {
310  std::for_each(mConnectedPorts.begin(), mConnectedPorts.end(), action);
311  } catch(Error& e) {
312  e.setCurrentLocation(__FUNCTION__, __FILE__, __LINE__);
313  throw;
314  }
315 }
std::list< PortSharedPtr > mConnectedPorts

+ Here is the call graph for this function:

template<typename _Action >
void torc::generic::PropertyContainer::applyOnAllProperties ( const _Action &  action)
throw (Error
)
inlineinherited

Apply action on all properties.

Parameters
[in]actionAction to be applied

Definition at line 113 of file PropertyContainer.hpp.

114  {
115  try {
116  mProperties.applyOnAll(action);
117  } catch(Error& e) {
118  e.setCurrentLocation(__FUNCTION__, __FILE__, __LINE__);
119  throw;
120  }
121 }
void applyOnAll(const _Action &action)
Definition: SymTab.hpp:192
SymTab< std::string, PropertySharedPtr > mProperties

+ Here is the call graph for this function:

template<typename _Action >
void torc::generic::Net::applyOnAllSubnets ( const _Action &  action)
throw (Error
)
inlineinherited

Apply action on all Subnets.

Parameters
[in]actionAction to be applied

Definition at line 284 of file generic/Net.hpp.

285  {
286  try {
287  mSubnets.applyOnAll(action);
288  } catch(Error& e) {
289  e.setCurrentLocation(__FUNCTION__, __FILE__, __LINE__);
290  throw;
291  }
292 }
void applyOnAll(const _Action &action)
Definition: SymTab.hpp:192
SymTab< std::string, NetSharedPtr, true > mSubnets

+ Here is the call graph for this function:

Connectable::Connection torc::generic::VectorNetBit::connect ( const NetSharedPtr inNet)
throw (Error
)
virtual
Exceptions
ErrorPointer to the Net object does not exists
  • Id : eMessageIdErrorPointerToItemDoesNotExist
  • Context Data
ErrorNet size does not match with vector net bit size
  • Id : eMessageIdErrorItemSizeMismatch
  • Context Data

Implements torc::generic::Connectable.

Definition at line 47 of file VectorNetBit.cpp.

47  {
48  if(!inNet) {
49  Error e(eMessageIdErrorPointerToItemDoesNotExist, __FUNCTION__, __FILE__, __LINE__);
50  e.saveContextData("Pointer to the Net object does not exist", inNet);
51  throw e;
52  }
53  if(inNet->getSize() != getSize()) {
54  Error e(eMessageIdErrorItemSizeMismatch, __FUNCTION__, __FILE__, __LINE__);
55  e.saveContextData("Net Size", inNet->getSize());
56  e.saveContextData("VectorNetBit Size", getSize());
57  throw e;
58  }
59  return Connectable::connect(inNet);
60 }
virtual Connection connect(const NetSharedPtr &inNet)=0
Definition: Connectable.cpp:60
virtual SizeType getSize() const

+ Here is the call graph for this function:

void torc::generic::VectorNetBit::disconnect ( const Connection inConnection)
throw (Error
)
virtual

Implements torc::generic::Connectable.

Definition at line 62 of file VectorNetBit.cpp.

62  {
63  Connectable::disconnect(inConnection);
64 }

+ Here is the call graph for this function:

void torc::generic::Connectable::disconnect ( const std::string &  inName)
throw (Error
)
inherited

Disconnect the named Net from this object.

Note
This metod can be overridden by derived classes. However, the method must call the on_connected() method after this. The sigConnected_ signal must also be invoked in the overriding method.
Parameters
[in]inNameName of the net to be Disconnected
Exceptions
ErrorProvided net was not found

Disconnect the named Net from this object.

Note
This metod can be overridden by derived classes. However, the method must call the on_connected() method after this. The sigConnected_ signal must also be invoked in the overriding method.
Parameters
[in]inNnameName of the net to be Disconnected
Exceptions
ErrorProvided net was not found

Definition at line 111 of file Connectable.cpp.

111  {
112  disconnect(std::find_if(mConnectedNets.begin(), mConnectedNets.end(),
113  boost::bind<bool>(std::equal_to<std::string>(),
114  boost::bind(boost::mem_fn(&Net::getName), _1), inName)));
115 }
std::list< NetSharedPtr > mConnectedNets
virtual const std::string getName() const
Definition: Nameable.hpp:89

+ Here is the call graph for this function:

void torc::generic::Connectable::disconnect ( const NetSharedPtr inNet)
throw (Error
)
inherited

Disconnect the given Net from this object.

Note
This metod can be overridden by derived classes. However, the method must call the on_disconnected() method after this. The sigDisconnected_ signal must also be invoked in the overriding method.
Parameters
[in]netPointer to a net
Exceptions
ErrorProvided net was not found

Disconnect the given Net from this object.

Note
This metod can be overridden by derived classes. However, the method must call the on_disconnected() method after this. The sigDisconnected_ signal must also be invoked in the overriding method.
Parameters
[in]inNetPointer to a net
Exceptions
ErrorProvided net was not found

Definition at line 128 of file Connectable.cpp.

128  {
129  disconnect(std::find(mConnectedNets.begin(), mConnectedNets.end(), inNet));
130 }
std::list< NetSharedPtr > mConnectedNets
void torc::generic::Net::disconnect ( )
throw (Error
)
virtualinherited

Reimplemented from torc::generic::Connectable.

Reimplemented in torc::generic::VectorNet, and torc::generic::NetBundle.

Definition at line 311 of file generic/Net.cpp.

311  {
312  if(!getName().empty()) {
313  log("Clearing net %s\n", getName().c_str());
314  }
315  mSubnets.clear();
316  //Don't try to optimize the following by using applyOnAll
317  // it causes memory corruption as the SymTab itself changes
318  // during disconnection
319  std::vector<PortSharedPtr> ports;
320  getConnectedPorts(ports, true);
321  void (Connectable::*fp)(const NetSharedPtr& net)
323  std::for_each(ports.begin(), ports.end(), boost::bind(fp, _1, getSharedThis()));
324  std::vector<PortReferenceSharedPtr> portRefs;
325  getConnectedPortRefs(portRefs, true);
326  std::for_each(portRefs.begin(), portRefs.end(), boost::bind(fp, _1, getSharedThis()));
327  std::vector<PortListSharedPtr> portLists;
328  getConnectedPortLists(portLists);
329  std::for_each(portLists.begin(), portLists.end(), boost::bind(fp, _1, getSharedThis()));
331 }
void log(const char *fmt,...)
Definition: Log.cpp:89
virtual void getConnectedPorts(std::vector< PortSharedPtr > &outPort, bool inSkipChildConnections=false) const
virtual void getConnectedPortRefs(std::vector< PortReferenceSharedPtr > &outPortRefs, bool inSkipChildConnections=false) const
boost::shared_ptr< Net > NetSharedPtr
virtual void getConnectedPortLists(std::vector< PortListSharedPtr > &outPortList) const
virtual const std::string getName() const
Definition: Nameable.hpp:89
SymTab< std::string, NetSharedPtr, true > mSubnets

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

PortSharedPtr torc::generic::Net::findConnectedPort ( const std::string &  inName)
throw (Error
)
inherited

Find a port connected to this net.

Parameters
[in]inNameName of the port. If not found, empty pointer is returned

Definition at line 166 of file generic/Net.cpp.

166  {
167  PortSharedPtr port;
168  std::list<PortSharedPtr>::iterator it = find_if(
169  mConnectedPorts.begin(),
170  mConnectedPorts.end(),
171  boost::bind<bool>(std::equal_to<std::string>(),
172  boost::bind(boost::mem_fn(&Port::getName), _1), inName));
173  if(it != mConnectedPorts.end()) {
174  port = *it;
175  }
176  return port;
177 }
std::list< PortSharedPtr > mConnectedPorts
virtual const std::string getName() const
Definition: Nameable.hpp:89
boost::shared_ptr< Port > PortSharedPtr

+ Here is the call graph for this function:

PortReferenceSharedPtr torc::generic::Net::findConnectedPortReference ( const std::string &  inName)
throw (Error
)
inherited

Find a port reference connected to this net.

Parameters
[in]inNameName of the port reference. If not found, empty pointer is returned

Definition at line 266 of file generic/Net.cpp.

266  {
267  PortReferenceSharedPtr portRef;
268  std::list<PortReferenceSharedPtr>::iterator it = find_if(
269  mConnectedPortRefs.begin(),
270  mConnectedPortRefs.end(),
271  boost::bind<bool>(std::equal_to<std::string>(),
272  boost::bind(boost::mem_fn(&PortReference::getName), _1), inName));
273  if(it != mConnectedPortRefs.end()) {
274  portRef = *it;
275  }
276  return portRef;
277 }
std::list< PortReferenceSharedPtr > mConnectedPortRefs
boost::shared_ptr< PortReference > PortReferenceSharedPtr

+ Here is the call graph for this function:

NetSharedPtr torc::generic::Net::findSubnet ( const std::string &  inName)
throw (Error
)
inherited

Find a subnet from belonging to this net.

Parameters
[in]inNameName of the subnet. If not found, empty pointer is returned

Definition at line 85 of file generic/Net.cpp.

85  {
86  NetSharedPtr subnet;
87  mSubnets.get(inName, subnet);
88  return subnet;
89 }
boost::shared_ptr< Net > NetSharedPtr
bool get(const KeyType &inKey, ValueType &outValue) const
Definition: SymTab.hpp:121
SymTab< std::string, NetSharedPtr, true > mSubnets
virtual const Pointer torc::generic::VectorBit< Net >::get ( const std::vector< SizeType > &  inIndices) const
throw (Error
)
virtualinherited

Get a specific member of this composition.

Parameters
[in]inIndicesA list of indices to be accessed. The number of indices must be equal to the number of dimensions.
Returns
An empty pointer is returned

Get a specific member of this composition.

Parameters
[in]indicesA list of indices to be accessed. The number of indices must be equal to the number of dimensions.
Returns
An empty pointer is returned

Implements torc::generic::Composite< Net >.

virtual const Pointer torc::generic::Composite< Net >::get ( const std::vector< SizeType > &  inIndices) const
throw (Error
)
pure virtualinherited

Get a specific member of this composition.

Note
This is relevant for Vector composition only. Other compositions return a NULL pointer
Parameters
[in]inIndicesA list of indices to be accessed. The number of indices must be equal to the number of dimensions.
Returns
A pointer to the child situated at the specified indices. For non-relevant types a NULL pointer is returned
Exceptions
ErrorIndex dimensions mismatch

Implemented in torc::generic::Vector< Net, VectorNetBit, VectorNetBit::Factory, true >, torc::generic::Bundle< Net >, torc::generic::VectorBit< Net >, and torc::generic::Scalar< Net >.

SizeType torc::generic::VectorBit< Net >::getAbsoluteIndex ( ) const
inlineinherited

+ Here is the caller graph for this function:

const NetAttributesSharedPtr torc::generic::Net::getAttributes ( ) const
inlineinherited

Get the attributes of the net. Attributes include criticality, netDelay etc.

Returns
Pointer to NetAttributes object.

Definition at line 303 of file generic/Net.hpp.

303  {
304  return mAttributes;
305 }
NetAttributesSharedPtr mAttributes
virtual void torc::generic::VectorBit< Net >::getChildren ( List outChildren) const
throw (Error
)
virtualinherited

Get children of this composition.

Parameters
[out]outChildrenA list of all children for this composition
Note
This wil return empty list for scalar

Get children of this composition.

Parameters
[out]outChildrenA list of all children for this composition

Implements torc::generic::Composite< Net >.

virtual void torc::generic::Composite< Net >::getChildren ( List outChildren) const
throw (Error
)
pure virtualinherited

Get children of this composition.

Note
This is relevant for Vector and Bundle compositions only. Other compositions return a NULL pointer
Parameters
[out]outChildrenA list of all children for this composition

Implemented in torc::generic::Vector< Net, VectorNetBit, VectorNetBit::Factory, true >, torc::generic::Scalar< Net >, and torc::generic::VectorBit< Net >.

const std::vector< std::string > & torc::generic::Commentable::getComments ( ) const
inlineinherited

Get the list of all comments

Returns
A list of all comments on this object

Definition at line 85 of file Commentable.hpp.

85  {
86  return mComments;
87 }
std::vector< std::string > mComments
Definition: Commentable.hpp:77
virtual CompositionType torc::generic::VectorBit< Net >::getCompositionType ( ) const
virtualinherited

Get composition type for this object

Returns
The CompositionType inSource eCompositionTypeVectorBit is returned

Get composition type for this object

Returns
The CompositionType inSource eCompositionTypeScalar is returned

Implements torc::generic::Composite< Net >.

virtual CompositionType torc::generic::Composite< Net >::getCompositionType ( ) const
pure virtualinherited
void torc::generic::VectorNetBit::getConnectedNets ( std::vector< NetSharedPtr > &  outNets,
bool  inSkipChildConnections = false 
) const
throw (Error
)
virtual

Reimplemented from torc::generic::Connectable.

Definition at line 66 of file VectorNetBit.cpp.

67  {
69  if(!parent) {
70  Error e(eMessageIdErrorPointerToItemDoesNotExist, __FUNCTION__, __FILE__, __LINE__);
71  e.saveContextData("Pointer to parent collection does not exist", parent);
72  throw e;
73  }
74  if(eCompositionTypeVector != parent->getCompositionType()) {
75  Error e(eMessageIdErrorCompositionTypeMismatch, __FUNCTION__, __FILE__, __LINE__);
76  e.saveContextData("Composition type mismatch", parent->getCompositionType());
77  throw e;
78  }
79  //First get connections exclusive to me
80  Net::getConnectedNets(outNets);
81 
82  if(!inSkipChildConnections) {
83  //Append cousins from nets that have been connected to my
84  //parent
85  VectorBit<Net>::List parentConnections;
86  parent->getConnectedNets(parentConnections, true);
87  VectorBit<Net>::List::iterator connNet = parentConnections.begin();
88  VectorBit<Net>::List::iterator connNetEnd = parentConnections.end();
89  const std::vector<VectorBit<Net>::SizeType>& myIndex = getIndices();
90  for(; connNet != connNetEnd; ++connNet) {
92  if(eCompositionTypeVector == (*connNet)->getCompositionType()) {
93  cousin = (*connNet)->get(myIndex);
94  //We don't want to mess up preservation
95  //by calling getChildren
96  } else //Must be a bundle
97  {
98  VectorBit<Net>::List bChildren;
99  (*connNet)->getChildren(bChildren);
100  cousin = bChildren[getAbsoluteIndex()];
101  //We assume List is a vector
102  }
103  if(!cousin) {
104  Error e(eMessageIdErrorPointerToItemDoesNotExist, __FUNCTION__, __FILE__, __LINE__);
105  e.saveContextData("Pointer to item does not exist", cousin);
106  throw e;
107  }
108  outNets.push_back(cousin);
109  }
110  //MAINTAINER_NOTE::Also check getConnectedPorts
111  // getConnectedPortReferences as they follow the same logic
112  }
113  return;
114 }
SizeType getAbsoluteIndex() const
boost::shared_ptr< Type > Pointer
Definition: Composite.hpp:55
virtual void getConnectedNets(std::vector< NetSharedPtr > &outNets, bool inSkipChildConnections=false) const
Definition: Connectable.cpp:45
virtual Pointer getParentCollection() const
const std::vector< SizeType > & getIndices() const

+ Here is the call graph for this function:

void torc::generic::Net::getConnectedPortLists ( std::vector< PortListSharedPtr > &  outPortList) const
virtualinherited

Appends vector of connected port lists

Parameters
[in]outPortListvector of port lists to be appended to

Definition at line 213 of file generic/Net.cpp.

213  {
214  outPortList.insert(outPortList.end(), mConnectedPortLists.begin(), mConnectedPortLists.end());
215  return;
216 }
std::list< PortListSharedPtr > mConnectedPortLists

+ Here is the caller graph for this function:

void torc::generic::VectorNetBit::getConnectedPortRefs ( std::vector< PortReferenceSharedPtr > &  outPortRefs,
bool  inSkipChildConnections = false 
) const
virtual

Reimplemented from torc::generic::Net.

Definition at line 163 of file VectorNetBit.cpp.

164  {
166  if(!parent) {
167  Error e(eMessageIdErrorPointerToItemDoesNotExist, __FUNCTION__, __FILE__, __LINE__);
168  e.saveContextData("Pointer to parent collection does not exist", parent);
169  throw e;
170  }
171  //Maintainer Note:: Check comments in getConnectedNets
172  if(eCompositionTypeVector != parent->getCompositionType()) {
173  Error e(eMessageIdErrorCompositionTypeMismatch, __FUNCTION__, __FILE__, __LINE__);
174  e.saveContextData("Composition type mismatch", parent->getCompositionType());
175  throw e;
176  }
177  //First get connections exclusive to me
178  Net::getConnectedPortRefs(outPortRefs);
179 
180  if(!inSkipChildConnections) {
181  //Append cousins from nets that have been connected to my
182  //parent
183  VectorBit<PortReference>::List parentConnections;
184  parent->getConnectedPortRefs(parentConnections, true);
185  VectorBit<PortReference>::List::iterator connPortRef = parentConnections.begin();
186  VectorBit<PortReference>::List::iterator connPortRefEnd = parentConnections.end();
187  const std::vector<VectorBit<Net>::SizeType>& myIndex = getIndices();
188  for(; connPortRef != connPortRefEnd; ++connPortRef) {
190  //Maintainer note:: Check comments in getConnectedNets
191  if(eCompositionTypeVector == (*connPortRef)->getCompositionType()) {
192  cousin = (*connPortRef)->get(myIndex);
193  } else {
195  (*connPortRef)->getChildren(bChildren);
196  cousin = bChildren[getAbsoluteIndex()];
197  }
198  if(!cousin) {
199  Error e(eMessageIdErrorPointerToItemDoesNotExist, __FUNCTION__, __FILE__, __LINE__);
200  e.saveContextData("Pointer to item does not exist", cousin);
201  throw e;
202  }
203  outPortRefs.push_back(cousin);
204  }
205  //MAINTAINER_NOTE::Also check getConnectedPorts
206  // getConnectedNets as they follow the same logic
207  }
208  return;
209 }
SizeType getAbsoluteIndex() const
boost::shared_ptr< Type > Pointer
Definition: Composite.hpp:55
virtual void getConnectedPortRefs(std::vector< PortReferenceSharedPtr > &outPortRefs, bool inSkipChildConnections=false) const
virtual Pointer getParentCollection() const
const std::vector< SizeType > & getIndices() const

+ Here is the call graph for this function:

void torc::generic::VectorNetBit::getConnectedPorts ( std::vector< PortSharedPtr > &  outPorts,
bool  inSkipChildConnections = false 
) const
virtual

Reimplemented from torc::generic::Net.

Definition at line 116 of file VectorNetBit.cpp.

117  {
119  if(!parent) {
120  Error e(eMessageIdErrorPointerToItemDoesNotExist, __FUNCTION__, __FILE__, __LINE__);
121  e.saveContextData("Pointer to parent collection does not exist", parent);
122  throw e;
123  }
124  if(eCompositionTypeVector != parent->getCompositionType()) {
125  Error e(eMessageIdErrorCompositionTypeMismatch, __FUNCTION__, __FILE__, __LINE__);
126  e.saveContextData("Composition type mismatch", parent->getCompositionType());
127  throw e;
128  }
129  //First get connections exclusive to me
130  Net::getConnectedPorts(outPorts);
131 
132  if(!inSkipChildConnections) {
133  //Append cousins from nets that have been connected to my
134  //parent
135  VectorBit<Port>::List parentConnections;
136  parent->getConnectedPorts(parentConnections, true);
137  VectorBit<Port>::List::iterator connPort = parentConnections.begin();
138  VectorBit<Port>::List::iterator connPortEnd = parentConnections.end();
139  const std::vector<VectorBit<Net>::SizeType>& myIndex = getIndices();
140  for(; connPort != connPortEnd; ++connPort) {
142  //Maintainer Note:: Check comments in getConnectedNets
143  if(eCompositionTypeVector == (*connPort)->getCompositionType()) {
144  cousin = (*connPort)->get(myIndex);
145  } else {
146  VectorBit<Port>::List bChildren;
147  (*connPort)->getChildren(bChildren);
148  cousin = bChildren[getAbsoluteIndex()];
149  }
150  if(!cousin) {
151  Error e(eMessageIdErrorPointerToItemDoesNotExist, __FUNCTION__, __FILE__, __LINE__);
152  e.saveContextData("Pointer to item does not exist", cousin);
153  throw e;
154  }
155  outPorts.push_back(cousin);
156  }
157  //MAINTAINER_NOTE::Also check getConnectedNets
158  // getConnectedPortReferences as they follow the same logic
159  }
160  return;
161 }
SizeType getAbsoluteIndex() const
boost::shared_ptr< Type > Pointer
Definition: Composite.hpp:55
virtual void getConnectedPorts(std::vector< PortSharedPtr > &outPort, bool inSkipChildConnections=false) const
virtual Pointer getParentCollection() const
const std::vector< SizeType > & getIndices() const

+ Here is the call graph for this function:

const std::vector<SizeType>& torc::generic::VectorBit< Net >::getIndices ( ) const
inlineinherited

Get the index of this bit in the vector.

Returns
A vector containing the indices to which this element belonged.

+ Here is the caller graph for this function:

const std::string torc::generic::Nameable::getName ( void  ) const
inlinevirtualinherited

Get the object name

Returns
Name of the object

Definition at line 89 of file Nameable.hpp.

89  {
90  return mName;
91 }

+ Here is the caller graph for this function:

Renamable::Name torc::generic::Renamable::getOriginalName ( ) const
inlinevirtualinherited

Get the new name provided for the object.

Returns
Name of the object

Definition at line 78 of file generic/Renamable.hpp.

78  {
79  return mOriginalName;
80 }

+ Here is the caller graph for this function:

const boost::shared_ptr<View > torc::generic::ParentedObject< View >::getParent ( ) const
inlineinherited

Get a pointer to the parent object

Returns
Pointer to parent

+ Here is the caller graph for this function:

virtual Pointer torc::generic::Composite< Net >::getParentCollection ( ) const
inlinevirtualinherited

Get a pointer to the parent collection

Returns
A pointer to the parent collection if present, empty pointer otherwise

+ Here is the caller graph for this function:

NetSharedPtr torc::generic::Net::getParentNet ( ) const
inlineinherited

Definition at line 294 of file generic/Net.hpp.

294  {
295  return mParentNet;
296 }
NetSharedPtr mParentNet
void torc::generic::PropertyContainer::getProperties ( std::map< std::string, PropertySharedPtr > &  outProperties) const
inlineinherited

Get the map of all properties

Parameters
[out]outPropertiesThe map of properties

Get the map of all properties

Returns
The map of properties

Definition at line 107 of file PropertyContainer.hpp.

108  {
109  mProperties.getValueMap(outProperties);
110  return;
111 }
void getValueMap(UserMap &outMap) const
Definition: SymTab.hpp:171
SymTab< std::string, PropertySharedPtr > mProperties

+ Here is the call graph for this function:

PropertySharedPtr torc::generic::PropertyContainer::getProperty ( const std::string &  inName)
inherited

Get a property

Parameters
[in]inNameName of the property to be retreived
Returns
Pointer to the property object if present, empty pointer otherwise.

Get a property

Parameters
[in]nameName of the property to be retreived
Returns
Pointer to the property object if present, empty pointer otherwise.

Definition at line 37 of file PropertyContainer.cpp.

37  {
38  PropertySharedPtr property;
39  if(!inName.empty()) {
40  mProperties.get(inName, property);
41  }
42  return property;
43 }
bool get(const KeyType &inKey, ValueType &outValue) const
Definition: SymTab.hpp:121
SymTab< std::string, PropertySharedPtr > mProperties
boost::shared_ptr< Property > PropertySharedPtr

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Pointer torc::generic::SelfReferencing< Net >::getSharedThis ( ) const
inlineinherited

Get a shared pointer to this object. A valid pointer is returned if weakThis was set. Otherwise this returns a NULL pointer. For Vector types, the second scenario is an exception condition and should be treated as such.

Returns
A shared pointer to this object

Get a shared pointer to this object. A valid pointer is returned if weakThis was set. Otherwise this returns a NULL pointer. For Vector types, the second scenario is an exception condition and should be treated as such.

Parameters
[out]ptrSet to a shared pointer to this object

+ Here is the caller graph for this function:

virtual SizeType torc::generic::VectorBit< Net >::getSize ( void  ) const
virtualinherited

Get the total number of bits of the composition

Returns
Number of bits

Implements torc::generic::Composite< Net >.

virtual size_t torc::generic::Composite< Net >::getSize ( void  ) const
pure virtualinherited
void torc::generic::Net::getSubnets ( std::vector< NetSharedPtr > &  outSubnets) const
inlineinherited

Definition at line 279 of file generic/Net.hpp.

279  {
280  mSubnets.getValues(outSubnets);
281  return;
282 }
void getValues(std::vector< ValueType > &outValues) const
Definition: SymTab.hpp:158
SymTab< std::string, NetSharedPtr, true > mSubnets

+ Here is the call graph for this function:

void torc::generic::UserDataContainer::getUserData ( std::list< std::string > &  outUserData) const
inlineinherited

Get the list of all userData

Parameters
[out]outUserDataThe list of all userData

Definition at line 78 of file UserDataContainer.hpp.

78  {
79  outUserData.insert(outUserData.end(), mUserData.begin(), mUserData.end());
80  return;
81 }
std::list< std::string > mUserData
void torc::generic::Connectable::onConnect ( )
throw (Error
)
protectedvirtualinherited

A polymorphic function that is called after a net is Connected to this object

Definition at line 144 of file Connectable.cpp.

144 {}
void torc::generic::Connectable::onDisconnect ( )
throw (Error
)
protectedvirtualinherited

A polymorphic function that is called after a net is Disconnected from this object

Definition at line 149 of file Connectable.cpp.

149 {}
void torc::generic::Net::removeConnectedPort ( const PortSharedPtr inPort)
throw (Error
)
protectedinherited

Definition at line 185 of file generic/Net.cpp.

185  {
186  std::list<PortSharedPtr>::iterator it = find(mConnectedPorts.begin(), mConnectedPorts.end(),
187  inPort);
188  if(it != mConnectedPorts.end()) {
189  mConnectedPorts.erase(it);
190  } else {
191  Error e(eMessageIdErrorItemNotFound, __FUNCTION__, __FILE__, __LINE__);
192  e.saveContextData("Name", inPort->getName());
193  throw e;
194  }
195  return;
196 
197 }
std::list< PortSharedPtr > mConnectedPorts

+ Here is the call graph for this function:

void torc::generic::Net::removeConnectedPortList ( const PortListSharedPtr inList)
throw (Error
)
protectedinherited

Definition at line 226 of file generic/Net.cpp.

226  {
227  std::list<PortListSharedPtr>::iterator it = find(mConnectedPortLists.begin(),
228  mConnectedPortLists.end(), inPortList);
229  if(it != mConnectedPortLists.end()) {
230  mConnectedPortLists.erase(it);
231  } else {
232  Error e(eMessageIdErrorItemNotFound, __FUNCTION__, __FILE__, __LINE__);
233  e.saveContextData("Name", std::string("PortList"));
234  throw e;
235  }
236  return;
237 
238 }
std::string string
std::list< PortListSharedPtr > mConnectedPortLists

+ Here is the call graph for this function:

void torc::generic::Net::removeConnectedPortReference ( const PortReferenceSharedPtr inPortRef)
throw (Error
)
protectedinherited

Definition at line 285 of file generic/Net.cpp.

285  {
286  std::list<PortReferenceSharedPtr>::iterator it = find(mConnectedPortRefs.begin(),
287  mConnectedPortRefs.end(), inPortRef);
288  if(it != mConnectedPortRefs.end()) {
289  mConnectedPortRefs.erase(it);
290  } else {
291  Error e(eMessageIdErrorItemNotFound, __FUNCTION__, __FILE__, __LINE__);
292  e.saveContextData("PortReference name", inPortRef->getName());
293  throw e;
294  }
295  return;
296 }
std::list< PortReferenceSharedPtr > mConnectedPortRefs

+ Here is the call graph for this function:

void torc::generic::Net::removeSubnet ( const std::string &  inName)
throw (Error
)
inherited

Remove a subnet from this net.

Parameters
inNameName of the object to be delete
Exceptions
ErrorCould not remove subnet, because subnet name is empty
  • Id : eMessageIdErrorEmptyItemName
  • Context Data
    • Subnet name - String
ErrorCould not remove subnet, because subnet not present.
  • Id : eMessageIdErrorItemNotFound
  • Context Data
    • Subnet name - String

Remove a subnet from this net.

Parameters
inNameName of the object to be delete
Exceptions
ErrorCould not remove subnet, because subnet name is empty
ErrorCould not remove subnet, because subnet not present.

Definition at line 99 of file generic/Net.cpp.

99  {
100  if(inName.empty()) {
101  Error e(eMessageIdErrorEmptyItemName, __FUNCTION__, __FILE__, __LINE__);
102  e.saveContextData("Subnet name", inName);
103  throw e;
104  }
105  if(false == mSubnets.remove(inName)) {
106  Error e(eMessageIdErrorItemNotFound, __FUNCTION__, __FILE__, __LINE__);
107  e.saveContextData("Subnet name", inName);
108  throw e;
109  }
110  return;
111 }
bool remove(const KeyType &inKey)
Definition: SymTab.hpp:153
SymTab< std::string, NetSharedPtr, true > mSubnets

+ Here is the call graph for this function:

void torc::generic::VectorBit< Net >::setAbsoluteIndex ( SizeType  inSource)
inherited
void torc::generic::Net::setAttributes ( const NetAttributesSharedPtr inSource)
inherited

Set the attributes of the net. Attributes include criticality, netDelay etc.

Parameters
[in]inSourcePointer to NetAttributes object.

Definition at line 122 of file generic/Net.cpp.

122  {
123  mAttributes = inSource;
124 }
NetAttributesSharedPtr mAttributes
void torc::generic::Commentable::setComments ( const std::vector< std::string > &  inSource)
inherited

Get the list of all comments

Parameters
[in]inSourceA list of all comments to be set on this object

Definition at line 45 of file Commentable.cpp.

45  {
46  mComments.insert(mComments.end(), inSource.begin(), inSource.end());
47 }
std::vector< std::string > mComments
Definition: Commentable.hpp:77
void torc::generic::Net::setConnectedPortRefs ( const std::vector< PortReferenceSharedPtr > &  inSource)
throw (Error
)
protectedinherited

Definition at line 298 of file generic/Net.cpp.

298  {
299  std::vector<PortReferenceSharedPtr>::const_iterator portRef = inSource.begin();
300  std::vector<PortReferenceSharedPtr>::const_iterator portRefEnd = inSource.end();
301  for(; portRef != portRefEnd; ++portRef) {
302  try {
303  addConnectedPortReference(*portRef);
304  } catch(Error& e) {
305  e.setCurrentLocation(__FUNCTION__, __FILE__, __LINE__);
306  throw;
307  }
308  }
309 }
void addConnectedPortReference(const PortReferenceSharedPtr &portRef)

+ Here is the call graph for this function:

void torc::generic::Net::setConnectedPorts ( const std::vector< PortSharedPtr > &  inSource)
throw (Error
)
protectedinherited

Definition at line 199 of file generic/Net.cpp.

199  {
200  std::vector<PortSharedPtr>::const_iterator port = inSource.begin();
201  std::vector<PortSharedPtr>::const_iterator portEnd = inSource.end();
202  for(; port != portEnd; ++port) {
203  try {
204  addConnectedPort(*port);
205  } catch(Error& e) {
206  e.setCurrentLocation(__FUNCTION__, __FILE__, __LINE__);
207  throw;
208  }
209  }
210 
211 }
void addConnectedPort(const PortSharedPtr &inPort)

+ Here is the call graph for this function:

void torc::generic::VectorBit< Net >::setIndices ( const std::vector< SizeType > &  inSource)
inherited

Set the index of this bit in the vector.

Parameters
[in]inSourceA vector of indices for this element
void torc::generic::Nameable::setName ( const std::string &  inSource)
throw (Error
)
inherited

Set a name for this object

Parameters
[in]inSourceName of the object
Exceptions
ErrorCould not set name, because name is empty (Will be used by array members)
  • Id : eMessageIdErrorEmptyItemName
  • Context Data

Set a name for this object

Parameters
[in]inSourceName of the object
Exceptions
ErrorCould not set name, because name is empty (Will be used by array members)

Definition at line 41 of file Nameable.cpp.

41  {
42  if(inSource.empty()) {
43  Error e(eMessageIdErrorEmptyItemName, __FUNCTION__, __FILE__, __LINE__);
44  e.saveContextData("Nameable", inSource);
45  throw e;
46  }
47  mName = inSource;
48 }

+ Here is the call graph for this function:

void torc::generic::Renamable::setOriginalName ( const Name inSource)
virtualinherited

Set the new name provided for the object.

Parameters
[in]inSourceName of the object

Definition at line 35 of file generic/Renamable.cpp.

35  {
36  mOriginalName = inSource;
37 }
virtual void torc::generic::ParentedObject< View >::setParent ( const boost::shared_ptr< View > &  inSource)
virtualinherited

Set a pointer to the parent

Parameters
[in]inSourceSet a pointer to the parent

+ Here is the caller graph for this function:

virtual void torc::generic::Composite< Net >::setParentCollection ( const Pointer inParentCollection)
inlinevirtualinherited

Set a pointer to a parnt composition.

Parameters
[in]inParentCollectionpointer to the parent collection (Vector/Bundle)

Set a pointer to a parnt composition.

Parameters
[in]parentCollectionpointer to the parent collection (Vector/Bundle)
void torc::generic::Net::setParentNet ( const NetSharedPtr inParent)
inherited

Definition at line 113 of file generic/Net.cpp.

113  {
114  mParentNet = inParent;
115 }
NetSharedPtr mParentNet
void torc::generic::PropertyContainer::setProperties ( const std::map< std::string, PropertySharedPtr > &  inSource)
inherited

Set the map of properties

Parameters
[in]inSourceThe map of properties

Definition at line 66 of file PropertyContainer.cpp.

66  {
67  std::map<std::string, PropertySharedPtr>::const_iterator it = inSource.begin();
68  for(; it != inSource.end(); it++) {
69  setProperty((*it).first, (*it).second);
70  }
71 }
bool setProperty(const std::string &inName, const PropertySharedPtr &inProperty)

+ Here is the call graph for this function:

bool torc::generic::PropertyContainer::setProperty ( const std::string &  inName,
const PropertySharedPtr inProperty 
)
inherited

Save the inSource of a property

Parameters
[in]inNameName of the property to be saved
[in]inPropertyPointer to the property object if present, empty pointer otherwise.
Returns
bool True if saved, false otherwise.

Save the inSource of a property

Parameters
[in]inNameName of the property to be saved
[in]inPopertyPointer to the property object if present, empty pointer otherwise.
Returns
bool True if saved, false otherwise.

Definition at line 53 of file PropertyContainer.cpp.

54  {
55  if(!inName.empty()) {
56  return mProperties.set(inName, inProperty);
57  }
58  return false;
59 }
bool set(const KeyType &inKey, const ValueType &inValue)
Definition: SymTab.hpp:132
SymTab< std::string, PropertySharedPtr > mProperties

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void torc::generic::Net::setSubnets ( const std::vector< NetSharedPtr > &  inSource)
throw (Error
)
inherited

Definition at line 126 of file generic/Net.cpp.

126  {
127  std::vector<NetSharedPtr>::const_iterator subnet = inSource.begin();
128  std::vector<NetSharedPtr>::const_iterator subEnd = inSource.end();
129  for(; subnet != subEnd; ++subnet) {
130  try {
131  addSubnet(*subnet);
132  } catch(Error& e) {
133  e.setCurrentLocation(__FUNCTION__, __FILE__, __LINE__);
134  throw;
135  }
136  }
137 }
void addSubnet(const NetSharedPtr &inSubnet)
Definition: generic/Net.cpp:63

+ Here is the call graph for this function:

void torc::generic::UserDataContainer::setUserData ( const std::list< std::string > &  inSource)
inherited

Set the list of userData

Parameters
[in]inSourceThe list of UserData

Definition at line 26 of file UserDataContainer.cpp.

26  {
27  mUserData.insert(mUserData.end(), inSource.begin(), inSource.end());
28 }
std::list< std::string > mUserData
void torc::generic::SelfReferencing< Net >::setWeakThis ( const WeakPointer inWeakThis)
inlineinherited

Set a weak pointer to this object. This will be used later to get a shared pointer to this object from within other member methods if required. This should be called by the Factory creating the object.

Parameters
[in]weakThisA weak pointer to this object
Connectable::Connected & torc::generic::Connectable::signalNetConnected ( )
inlineinherited

A signal to indicate that a new connection has been made

Definition at line 167 of file Connectable.hpp.

167  {
168  return mSigNetConnected;
169 }
Connectable::Disconnected & torc::generic::Connectable::signalNetDisconnected ( )
inlineinherited

A signal to indicate that a new connection has been made

Definition at line 174 of file Connectable.hpp.

174  {
175  return mSigNetDisconnected;
176 }
Disconnected mSigNetDisconnected

The documentation for this class was generated from the following files: