Rosetta 3.4
Public Member Functions | Protected Attributes
protocols::wum::WorkUnitList Class Reference

WOrkUnitList is a store for WorkUnitCOPs. THe purpose of this class is to store all the possible WorkUnits that a protocol might need. When needed these are cloned and then used. THis class acts like a library of WorkUnit blueprints. More...

#include <WorkUnitList.hh>

Collaboration diagram for protocols::wum::WorkUnitList:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 WorkUnitList ()
void register_work_unit (const std::string &name, WorkUnitBaseOP the_work_unit)
 Add a WorkUnit to the list, each workunit must be named with a string that is used later to retrieve it !
const WorkUnitBaseCOP get_work_unit (const std::string &name) const
 Return a COP to a workunit with a given name. If multiple WUs were registered with the same name, the first is returned.
const WorkUnitBaseOP get_work_unit_clone (const std::string &name) const
 Return an OP to a workunit with a given name but clone it.
const WorkUnitBaseCOP get_work_unit (const WorkUnitBase &wu) const
 Return an OP to a workunit with the same name as the one given as a parameter.
const WorkUnitBaseOP get_work_unit_clone (const WorkUnitBase &wu) const
 Return an OP to a workunit with the same name as the one given as a parameter, but as a clone.
void merge (const WorkUnitList &source)

Protected Attributes

std::map< std::string,
WorkUnitBaseCOP
work_unit_list_
 An STL map is used to associate the WUs with strings.

Detailed Description

WOrkUnitList is a store for WorkUnitCOPs. THe purpose of this class is to store all the possible WorkUnits that a protocol might need. When needed these are cloned and then used. THis class acts like a library of WorkUnit blueprints.


Constructor & Destructor Documentation

protocols::wum::WorkUnitList::WorkUnitList ( ) [inline]

Member Function Documentation

const WorkUnitBaseCOP protocols::wum::WorkUnitList::get_work_unit ( const std::string &  name) const

Return a COP to a workunit with a given name. If multiple WUs were registered with the same name, the first is returned.

References protocols::wum::TR(), and work_unit_list_.

Referenced by protocols::wum::MPI_Relax::fill_outbound_queue(), get_work_unit_clone(), protocols::wum::WorkUnitManager::read_work_unit(), and protocols::wum::MPI_WorkUnitManager::receive_MPI_workunit().

const WorkUnitBaseCOP protocols::wum::WorkUnitList::get_work_unit ( const WorkUnitBase wu) const [inline]

Return an OP to a workunit with the same name as the one given as a parameter.

References get_work_unit(), and protocols::wum::WorkUnitBase::get_wu_type().

Referenced by get_work_unit().

const WorkUnitBaseOP protocols::wum::WorkUnitList::get_work_unit_clone ( const WorkUnitBase wu) const [inline]

Return an OP to a workunit with the same name as the one given as a parameter, but as a clone.

References get_work_unit(), and protocols::wum::WorkUnitBase::get_wu_type().

const WorkUnitBaseOP protocols::wum::WorkUnitList::get_work_unit_clone ( const std::string &  name) const [inline]

Return an OP to a workunit with a given name but clone it.

References get_work_unit().

void protocols::wum::WorkUnitList::merge ( const WorkUnitList source)
void protocols::wum::WorkUnitList::register_work_unit ( const std::string &  name,
WorkUnitBaseOP  the_work_unit 
)

Add a WorkUnit to the list, each workunit must be named with a string that is used later to retrieve it !

References make_table_of_pilot_apps::name, and work_unit_list_.

Referenced by protocols::wum::MPI_Relax::register_work_units().


Member Data Documentation

std::map< std::string, WorkUnitBaseCOP > protocols::wum::WorkUnitList::work_unit_list_ [protected]

An STL map is used to associate the WUs with strings.

Referenced by get_work_unit(), merge(), and register_work_unit().


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines