SH::ShTransfer Class Reference
[Buffer Management]

A Storage Transfer function. More...

#include <ShMemory.hpp>

Inheritance diagram for SH::ShTransfer:

Inheritance graph
[legend]
List of all members.

Public Member Functions

virtual ~ShTransfer ()
virtual bool transfer (const ShStorage *from, ShStorage *to)=0
 Returns true if the transfer succeeded.
virtual int cost (const ShStorage *from, const ShStorage *to)=0
 Returns -1 if transfer impossible, otherwise the cost of transfer.

Protected Member Functions

 ShTransfer (const std::string &from, const std::string &to)

Detailed Description

A Storage Transfer function.

A transfer specifies the cost and manner of transferring data from one storage to another. Static instances of these should be created for any possible storage transfers. Use the ShStorage::addTransfer() function to add a transfer to the list.

See also:
ShMemory

ShStorage

Definition at line 110 of file ShMemory.hpp.


Member Function Documentation

virtual int SH::ShTransfer::cost const ShStorage from,
const ShStorage to
[pure virtual]
 

Returns -1 if transfer impossible, otherwise the cost of transfer.

Todo:
Perhaps this needs more information, e.g. size of the storages.

Implemented in SH::ShHostHostTransfer.


The documentation for this class was generated from the following files:
Generated on Wed Nov 9 15:35:39 2005 for Sh by  doxygen 1.4.5