OpenASIP  2.0
Public Member Functions | Private Attributes | List of all members
TTAProgram::TPEFProgramFactory::CacheKey Class Reference

Cache key for resources that are accessed from MOM(s) More...

Collaboration diagram for TTAProgram::TPEFProgramFactory::CacheKey:
Collaboration graph

Public Member Functions

 CacheKey (const TTAMachine::Bus &aBus, TTAMachine::Socket::Direction aDirection, TPEF::MoveElement::FieldType aType, HalfWord anUnitId, HalfWord anIndex)
 
bool operator< (const CacheKey &keyToCompare) const
 

Private Attributes

const TTAMachine::Busbus_
 Bus that was used for transport. More...
 
TTAMachine::Socket::Direction direction_
 Direction if the port was read or written. More...
 
TPEF::MoveElement::FieldType type_
 Type of the accessed unit. More...
 
HalfWord unitId_
 unit id of the corresponding TPEF resource element. More...
 
HalfWord index_
 Index of the corresponding TPEF resource element. More...
 

Detailed Description

Cache key for resources that are accessed from MOM(s)

Definition at line 191 of file TPEFProgramFactory.hh.

Constructor & Destructor Documentation

◆ CacheKey()

TTAProgram::TPEFProgramFactory::CacheKey::CacheKey ( const TTAMachine::Bus aBus,
TTAMachine::Socket::Direction  aDirection,
TPEF::MoveElement::FieldType  aType,
HalfWord  anUnitId,
HalfWord  anIndex 
)
inline

Definition at line 193 of file TPEFProgramFactory.hh.

197  :
198  bus_(aBus), direction_(aDirection), type_(aType),
199  unitId_(anUnitId), index_(anIndex) { }

Member Function Documentation

◆ operator<()

bool TTAProgram::TPEFProgramFactory::CacheKey::operator< ( const CacheKey keyToCompare) const
inline

Definition at line 201 of file TPEFProgramFactory.hh.

201  {
202 
203  if (direction_ < keyToCompare.direction_) return true;
204  else if (direction_ > keyToCompare.direction_) return false;
205 
206  if (type_ < keyToCompare.type_) return true;
207  else if (type_ > keyToCompare.type_) return false;
208 
209  if (unitId_ < keyToCompare.unitId_ ) return true;
210  else if (unitId_ > keyToCompare.unitId_ ) return false;
211 
212  if (index_ < keyToCompare.index_ ) return true;
213  else if (index_ > keyToCompare.index_) return false;
214 
215  if (&bus_ < &(keyToCompare.bus_)) return true;
216 
217  return false;
218  }

References bus_, direction_, index_, type_, and unitId_.

Member Data Documentation

◆ bus_

const TTAMachine::Bus& TTAProgram::TPEFProgramFactory::CacheKey::bus_
private

Bus that was used for transport.

Definition at line 222 of file TPEFProgramFactory.hh.

Referenced by operator<().

◆ direction_

TTAMachine::Socket::Direction TTAProgram::TPEFProgramFactory::CacheKey::direction_
private

Direction if the port was read or written.

Definition at line 224 of file TPEFProgramFactory.hh.

Referenced by operator<().

◆ index_

HalfWord TTAProgram::TPEFProgramFactory::CacheKey::index_
private

Index of the corresponding TPEF resource element.

Definition at line 230 of file TPEFProgramFactory.hh.

Referenced by operator<().

◆ type_

TPEF::MoveElement::FieldType TTAProgram::TPEFProgramFactory::CacheKey::type_
private

Type of the accessed unit.

Definition at line 226 of file TPEFProgramFactory.hh.

Referenced by operator<().

◆ unitId_

HalfWord TTAProgram::TPEFProgramFactory::CacheKey::unitId_
private

unit id of the corresponding TPEF resource element.

Definition at line 228 of file TPEFProgramFactory.hh.

Referenced by operator<().


The documentation for this class was generated from the following file:
TTAProgram::TPEFProgramFactory::CacheKey::unitId_
HalfWord unitId_
unit id of the corresponding TPEF resource element.
Definition: TPEFProgramFactory.hh:228
TTAProgram::TPEFProgramFactory::CacheKey::bus_
const TTAMachine::Bus & bus_
Bus that was used for transport.
Definition: TPEFProgramFactory.hh:222
TTAProgram::TPEFProgramFactory::CacheKey::type_
TPEF::MoveElement::FieldType type_
Type of the accessed unit.
Definition: TPEFProgramFactory.hh:226
TTAProgram::TPEFProgramFactory::CacheKey::direction_
TTAMachine::Socket::Direction direction_
Direction if the port was read or written.
Definition: TPEFProgramFactory.hh:224
TTAProgram::TPEFProgramFactory::CacheKey::index_
HalfWord index_
Index of the corresponding TPEF resource element.
Definition: TPEFProgramFactory.hh:230