torc-master
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
torc::architecture::Arc Class Reference

Encapsulation of an arc between two tilewires. More...

#include <Arc.hpp>

+ Collaboration diagram for torc::architecture::Arc:

Public Member Functions

 Arc (void)
 Null constructor. More...
 
 Arc (const Tilewire &inSourceTilewire, const Tilewire &inSinkTilewire)
 Public constructor. More...
 
const TilewiregetSourceTilewire (void) const
 Returns the source tilewire. More...
 
const TilewiregetSinkTilewire (void) const
 Returns the sink tilewire. More...
 
bool operator== (const Arc &rhs) const
 Equality operator. More...
 
bool operator< (const Arc &rhs) const
 Comparison operator. More...
 
bool isUndefined (void) const
 

Protected Attributes

Tilewire mSourceTilewire
 The source tilewire. More...
 
Tilewire mSinkTilewire
 The sink tilewire. More...
 

Friends

std::size_t hash_value (const Arc &inArc)
 Return a hash value for the specified arc. More...
 

Detailed Description

Encapsulation of an arc between two tilewires.

Definition at line 28 of file Arc.hpp.

Constructor & Destructor Documentation

torc::architecture::Arc::Arc ( void  )
inline

Null constructor.

The source and sink tilewires will be set to Tilewire::sInvalid.

Definition at line 39 of file Arc.hpp.

Tilewire mSinkTilewire
The sink tilewire.
Definition: Arc.hpp:34
Tilewire mSourceTilewire
The source tilewire.
Definition: Arc.hpp:32
torc::architecture::Arc::Arc ( const Tilewire inSourceTilewire,
const Tilewire inSinkTilewire 
)
inline

Public constructor.

Definition at line 41 of file Arc.hpp.

42  : mSourceTilewire(inSourceTilewire), mSinkTilewire(inSinkTilewire) {}
Tilewire mSinkTilewire
The sink tilewire.
Definition: Arc.hpp:34
Tilewire mSourceTilewire
The source tilewire.
Definition: Arc.hpp:32

Member Function Documentation

const Tilewire& torc::architecture::Arc::getSinkTilewire ( void  ) const
inline

Returns the sink tilewire.

Definition at line 47 of file Arc.hpp.

47 { return mSinkTilewire; }
Tilewire mSinkTilewire
The sink tilewire.
Definition: Arc.hpp:34

+ Here is the caller graph for this function:

const Tilewire& torc::architecture::Arc::getSourceTilewire ( void  ) const
inline

Returns the source tilewire.

Definition at line 45 of file Arc.hpp.

45 { return mSourceTilewire; }
Tilewire mSourceTilewire
The source tilewire.
Definition: Arc.hpp:32

+ Here is the caller graph for this function:

bool torc::architecture::Arc::isUndefined ( void  ) const
inline

Definition at line 61 of file Arc.hpp.

61  {
63  }
Tilewire mSinkTilewire
The sink tilewire.
Definition: Arc.hpp:34
Tilewire mSourceTilewire
The source tilewire.
Definition: Arc.hpp:32
bool isUndefined(void) const
Definition: Tilewire.hpp:86

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

bool torc::architecture::Arc::operator< ( const Arc rhs) const
inline

Comparison operator.

Definition at line 54 of file Arc.hpp.

54  {
55  if (mSinkTilewire < rhs.mSinkTilewire) return true;
56  if (mSinkTilewire == rhs.mSinkTilewire
57  && mSourceTilewire < rhs.mSourceTilewire) return true;
58  return false;
59  }
Tilewire mSinkTilewire
The sink tilewire.
Definition: Arc.hpp:34
Tilewire mSourceTilewire
The source tilewire.
Definition: Arc.hpp:32
bool torc::architecture::Arc::operator== ( const Arc rhs) const
inline

Equality operator.

Definition at line 50 of file Arc.hpp.

50  {
51  return mSourceTilewire == rhs.mSourceTilewire && mSinkTilewire == rhs.mSinkTilewire;
52  }
Tilewire mSinkTilewire
The sink tilewire.
Definition: Arc.hpp:34
Tilewire mSourceTilewire
The source tilewire.
Definition: Arc.hpp:32

Friends And Related Function Documentation

std::size_t hash_value ( const Arc inArc)
friend

Return a hash value for the specified arc.

Definition at line 25 of file Arc.cpp.

25  {
26  std::size_t seed = 0;
27  boost::hash_combine(seed, inArc.getSourceTilewire());
28  boost::hash_combine(seed, inArc.getSinkTilewire());
29  return seed;
30  }

Field Documentation

Tilewire torc::architecture::Arc::mSinkTilewire
protected

The sink tilewire.

Definition at line 34 of file Arc.hpp.

Tilewire torc::architecture::Arc::mSourceTilewire
protected

The source tilewire.

Definition at line 32 of file Arc.hpp.


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