torc::generic::PortList Class Reference

Represents an ordered list of port references. More...

#include <PortList.hpp>

Inheritance diagram for torc::generic::PortList:

Inheritance graph
[legend]
Collaboration diagram for torc::generic::PortList:

Collaboration graph
[legend]

List of all members.

Public Types

typedef PortElement PortListElement
typedef VisitorType< PortListVisitor

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)
size_t getSize () const throw ()
void addChildPort (const PortSharedPtr &inPort) throw ()
void addChildPortReference (const PortReferenceSharedPtr &inPortRef) throw ()
void getChildren (std::list< PortListElement > &outPorts) throw ()

Private Member Functions

template<typename _Tp>
void connectElementToNet (const NetSharedPtr &inNet, const boost::shared_ptr< _Tp > &inType, size_t &inoutCurrentWidth) throw (Error)

Private Attributes

std::list< PortListElementmElements

Friends

class FactoryType< PortList >

Classes

class  Factory


Detailed Description

Represents an ordered list of port references.

The PortList class represents an ordered list of port references. Such objects in EDIF are declard using the (portList portRefName1 portRefName2 ... ) syntax.

Definition at line 46 of file PortList.hpp.


Member Function Documentation

void torc::generic::PortList::accept ( BaseVisitor inoutVisitor  )  throw (Error) [virtual]

Recive a visitor to this class. The visit method of the visitor is called and a reference to this object is passed as a parameter. It has to be noted however, that a dynamic_cast is performed inside this method. If the cast fails, an appropriate exception is thrown by this method. This sitation can arise when the passed Visitor object does not inherit from the appropriate visitor specialization. See Visitor documentation for more details.

Parameters:
[in,out] inoutVisitor A reference to the visitor object
Exceptions:
Error Visitor type inappropriate for visiting this object or any other error thrown by the Visitor::throw() method.

Definition at line 78 of file PortList.cpp.

Connectable::Connection torc::generic::PortList::connect ( const NetSharedPtr &  inNet  )  throw (Error) [virtual]

Connect a Net to this object.

Parameters:
[in] inNet A pointer to the Net object that needs to be connected
Returns:
A connection that has been established. This can be used later for disconnection.

Implements torc::generic::Connectable.

Definition at line 183 of file PortList.cpp.

virtual void torc::generic::PortList::disconnect ( const Connection inConnection  )  throw (Error) [virtual]

Disconnect a Net from this object.

Parameters:
[in] inConnection A connection as returned by the connect() method
Exceptions:
Error Provided connection is invalid

size_t torc::generic::PortList::getSize ( void   )  const throw ()

Get the total number of bits of the composition

Returns:
Number of bits

Definition at line 250 of file PortList.cpp.

void torc::generic::PortList::addChildPort ( const PortSharedPtr &  inPort  )  throw ()

Add a port to the port list.

Parameters:
[in] inPort Pointer to port to be added.

Definition at line 273 of file PortList.cpp.

void torc::generic::PortList::addChildPortReference ( const PortReferenceSharedPtr &  inPortRef  )  throw ()

Add a port reference to the port list.

Parameters:
[in] inPortRef Pointer to port reference to be added.

Definition at line 278 of file PortList.cpp.

void torc::generic::PortList::getChildren ( std::list< PortListElement > &  outPorts  )  throw ()

Get all the children of this composition

Returns:
[out] outPorts List containing all children

Definition at line 284 of file PortList.cpp.


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

Generated on Thu Oct 13 16:50:19 2011 for TORC by  doxygen 1.5.6