Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

STopology Class Reference

#include <STopology.h>

Inherits STypeInfo, and SObservable.

Inherited by SHypercube [virtual], SMeshN [virtual], and SSetTopology [virtual].

Inheritance diagram for STopology:

Inheritance graph
[legend]
List of all members.

Public Methods

 STopology ()
virtual ~STopology ()
virtual STopologyModgetModifier ()=0
virtual int getCount () const=0
virtual int getIDAt (int pos) const=0
virtual int getPos (int ID) const=0
virtual bool isPosFree (int pos) const=0
virtual leda_list< int > getFreePos () const
virtual bool canEmbedAt (const STopology &top, int pos) const=0
virtual leda_list< int > canEmbedAt (const STopology &top) const
virtual void embed (const STopology &top, int pos, int ID)=0
virtual void embed (const STopology &top, const SComplexPosition *pComplexPos, int ID)
virtual void remove (int ID)=0
virtual leda_list< int > getEmbeddedIDs () const
virtual void clear ()
virtual bool fitsInto (const STopology *top) const=0
virtual leda_string getClassifier () const=0
virtual bool isInstanceOf (const leda_string &classifier) const=0
virtual void assureInstanceOf (const leda_string &classifier) const=0
void addObserver (SObserver &obs)
void deleteObserver (SObserver &obs)
void notifyObservers (const SEvent &event)

Detailed Description

Base class for topologies of jobs and machines. Jobs and machines have a topology which handles the embedding of jobs in machines. A topology can for example be a mesh. Machines in a classical scheduling problem are just sets of points and each job is a single point. Topologies can be asked if a certain embedding is possible and they can also administrate the embedding. Access the modifier in order to set properties.
See also:
STopologyMod


Constructor & Destructor Documentation

STopology::STopology   [inline]
 

Contructor

virtual STopology::~STopology   [inline, virtual]
 

Destructor


Member Function Documentation

void SObservable::addObserver SObserver   obs [inline, inherited]
 

Here another component can register himself as observer of this component

Parameters:
obs  observer that wants to be notified of events created by this class

virtual void STypeInfo::assureInstanceOf const leda_string &    classifier const [pure virtual, inherited]
 

The same as isInstanceOf(), only that the program is stopped with an error in case of failure

Parameters:
classifier  e.g. "P", "Q", "R", etc

leda_list< int > STopology::canEmbedAt const STopology &    top const [virtual]
 

Return a list of all positions where the topology may be embedded. Default implementation: just call canEmbedAt for all free positions

Parameters:
top  topology
Returns:
list of positions

Reimplemented in SSetTopology, and SSingleTopology.

virtual bool STopology::canEmbedAt const STopology &    top,
int    pos
const [pure virtual]
 

Return whether the topology can be embedded at a certain position

Parameters:
top  topology
pos  position
Returns:
true if topology can be embedded, otherwise false

Implemented in SHypercube, SMeshN, SSetTopology, and SSingleTopology.

void STopology::clear   [virtual]
 

Remove all embedded objects. Attention: This method has a very inefficient default implementation.

Reimplemented in SHypercube, and SMeshN.

void SObservable::deleteObserver SObserver   obs [inline, inherited]
 

Here another component can delete himself from the list of observers of this component

Parameters:
obs  observer that doesn't want to be notified anymore

virtual void STopology::embed const STopology &    top,
const SComplexPosition   pComplexPos,
int    ID
[inline, virtual]
 

Reimplemented in SHypercube, and SMeshN.

virtual void STopology::embed const STopology &    top,
int    pos,
int    ID
[pure virtual]
 

Embed a topology.

Parameters:
top  topology
pos  position where topology is embedded
ID  ID of the embedded topology

Implemented in SHypercube, SMeshN, SSetTopology, and SSingleTopology.

virtual bool STopology::fitsInto const STopology *    top const [pure virtual]
 

Test whether this Topology is at most as large as another

Parameters:
top  topology to compare with

Implemented in SHypercube, SMeshN, SSetTopology, and SSingleTopology.

virtual leda_string STypeInfo::getClassifier   [pure virtual, inherited]
 

Get the classifier of the object, using the classification scheme. E.g. "P" for Identical Processors

Returns:
classifier string

virtual int STopology::getCount   [pure virtual]
 

Return the number of positions in the linearized representation. Only positions 0..getCount()-1 are allowed.

Returns:
number of positions

Implemented in SHypercube, SMeshN, SSetTopology, and SSingleTopology.

leda_list< int > STopology::getEmbeddedIDs   [virtual]
 

Get all IDs that are currently embedded in the topology. Attention: This method has a very inefficient default implementation.

Returns:
list of embedded IDs

leda_list< int > STopology::getFreePos   [virtual]
 

Get a list of all positions where no topology is overlapping

Returns:
list of free positions

Reimplemented in SSetTopology, and SSingleTopology.

virtual int STopology::getIDAt int    pos const [pure virtual]
 

Return ID of the topology which is overlapping position 'pos'

Parameters:
pos  position
Returns:
topology ID (-1 if none)

Implemented in SHypercube, SMeshN, SSetTopology, and SSingleTopology.

virtual STopologyMod& STopology::getModifier   [pure virtual]
 

Get access to the modifier

Implemented in SHypercube, SLineTopology, SMeshN, SMeshTopology, SSetTopology, and SSingleTopology.

virtual int STopology::getPos int    ID const [pure virtual]
 

Return position at which the topology with id 'ID' is currently embedded

Parameters:
ID  topology ID
Returns:
position

Implemented in SHypercube, SMeshN, SSetTopology, and SSingleTopology.

virtual bool STypeInfo::isInstanceOf const leda_string &    classifier const [pure virtual, inherited]
 

Checks whether the object is an instance of the specified or a specialized class

Parameters:
classifier  e.g. "P", "Q", "R", etc
Returns:
true if the object can be casted to the specified class

virtual bool STopology::isPosFree int    pos const [pure virtual]
 

Return whether no topology overlaps with 'pos'

Parameters:
pos  position
Returns:
true if no topology overlaps with 'pos', otherise false

Implemented in SHypercube, SMeshN, SSetTopology, and SSingleTopology.

void SObservable::notifyObservers const SEvent   event [inline, inherited]
 

Inform all observers of this component about an event. The Observers will receive this event by their SObserver::update()-method.

Parameters:
event  an event that is sent to all observers of this component
See also:
SObserver::update()

virtual void STopology::remove int    ID [pure virtual]
 

Reverse the embedding

Parameters:
ID  ID of topology

Implemented in SHypercube, SMeshN, SSetTopology, and SSingleTopology.


The documentation for this class was generated from the following files:
Generated on Thu May 22 16:50:55 2003 for Sketch-it! by doxygen1.2.18