PaCO++  0.05
paco_comSchedule_libgraph Class Reference

#include <paco_libgraph_comScheduling.h>

Inheritance diagram for paco_comSchedule_libgraph:
Collaboration diagram for paco_comSchedule_libgraph:

List of all members.

Public Member Functions

void build_idx ()
kbps_approximation * get_kbps () const
unsigned int getDst (const unsigned phase, const unsigned id)
unsigned int getElementPhase (const unsigned phase)
void * getInfo (const unsigned phase, const unsigned id)
unsigned int getNbPhases ()
unsigned int getSize (const unsigned phase, const unsigned id)
unsigned int getSrc (const unsigned phase, const unsigned id)
 paco_comSchedule_libgraph (kbps_approximation *k)

Protected Member Functions

unsigned int _idx (const unsigned phase, const unsigned id)

Protected Attributes

kbps_approximation * _kbps
unsigned int * _tmp_idx

Detailed Description

Definition at line 7 of file paco_libgraph_comScheduling.h.


Constructor & Destructor Documentation

paco_comSchedule_libgraph::paco_comSchedule_libgraph ( kbps_approximation *  k) [inline]

Definition at line 19 of file paco_libgraph_comScheduling.h.

: _kbps(k), _tmp_idx(NULL) {}

Member Function Documentation

unsigned int paco_comSchedule_libgraph::_idx ( const unsigned  phase,
const unsigned  id 
) [inline, protected]

Definition at line 13 of file paco_libgraph_comScheduling.h.

References _tmp_idx.

Referenced by getDst(), getInfo(), getSize(), and getSrc().

  {
    return _tmp_idx[phase]+id;
  }

Definition at line 23 of file paco_libgraph_comScheduling.h.

References _tmp_idx, getElementPhase(), and getNbPhases().

Referenced by paco_comScheduling_libgraph::computeScheduling().

  {
    if (_tmp_idx) {
      delete[] _tmp_idx;
    }
    
    _tmp_idx = new unsigned int[this->getNbPhases()];
    _tmp_idx[0]=0;
    for(unsigned i=1;i<getNbPhases(); i++)
      _tmp_idx[i]=_tmp_idx[i-1]+getElementPhase(i-1);
  }

Here is the call graph for this function:

kbps_approximation* paco_comSchedule_libgraph::get_kbps ( ) const [inline]

Definition at line 21 of file paco_libgraph_comScheduling.h.

References _kbps.

Referenced by paco_comScheduling_libgraph::computeScheduling().

{ return _kbps; }
unsigned int paco_comSchedule_libgraph::getDst ( const unsigned  phase,
const unsigned  id 
) [inline, virtual]

Implements paco_comSchedule.

Definition at line 46 of file paco_libgraph_comScheduling.h.

References _idx(), and _kbps.

  {
    return _kbps->comms[_idx(phase, id)].dst;
  }

Here is the call graph for this function:

unsigned int paco_comSchedule_libgraph::getElementPhase ( const unsigned  phase) [inline, virtual]

Implements paco_comSchedule.

Definition at line 38 of file paco_libgraph_comScheduling.h.

References _kbps.

Referenced by build_idx().

  {
    return _kbps->infophases[phase+1];
  }
void* paco_comSchedule_libgraph::getInfo ( const unsigned  phase,
const unsigned  id 
) [inline, virtual]

Implements paco_comSchedule.

Definition at line 55 of file paco_libgraph_comScheduling.h.

References _idx(), and _kbps.

  {
    return _kbps->comms[_idx(phase, id)].info;    
  }

Here is the call graph for this function:

unsigned int paco_comSchedule_libgraph::getNbPhases ( ) [inline, virtual]

Implements paco_comSchedule.

Definition at line 35 of file paco_libgraph_comScheduling.h.

References _kbps.

Referenced by build_idx().

                             {
    return _kbps->infophases[0];
  }
unsigned int paco_comSchedule_libgraph::getSize ( const unsigned  phase,
const unsigned  id 
) [inline, virtual]

Implements paco_comSchedule.

Definition at line 50 of file paco_libgraph_comScheduling.h.

References _idx(), and _kbps.

  {
    return _kbps->comms[_idx(phase, id)].weight;
  }

Here is the call graph for this function:

unsigned int paco_comSchedule_libgraph::getSrc ( const unsigned  phase,
const unsigned  id 
) [inline, virtual]

Implements paco_comSchedule.

Definition at line 42 of file paco_libgraph_comScheduling.h.

References _idx(), and _kbps.

  {
    return _kbps->comms[_idx(phase, id)].src;
  }

Here is the call graph for this function:


Member Data Documentation

kbps_approximation* paco_comSchedule_libgraph::_kbps [protected]
unsigned int* paco_comSchedule_libgraph::_tmp_idx [protected]

Definition at line 12 of file paco_libgraph_comScheduling.h.

Referenced by _idx(), and build_idx().


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