CYCLUS
Public Member Functions | List of all members
cyclus::toolkit::SupplyDemandManager Class Reference

Detailed Description

This is a manager class that manages a set of commodities.

Those commodities have a certain demand function associated with them and a list of producers who can produce the commodities.

The SupplyDemandManager simply keeps track of this information and provides the demand and supply of a commodity at a given time. What to do with this information is left to the user of the SupplyDemandManager.

Definition at line 23 of file supply_demand_manager.h.

#include <supply_demand_manager.h>

Inheritance diagram for cyclus::toolkit::SupplyDemandManager:
cyclus::toolkit::AgentManaged

Public Member Functions

double Demand (Commodity &commodity, int time)
 
SymFunction::Ptr DemandFunction (Commodity &commodity)
 
bool ManagesCommodity (Commodity &commodity)
 
void RegisterCommodity (Commodity &commodity, SymFunction::Ptr demand)
 
void RegisterProducerManager (CommodityProducerManager *cpm)
 
double Supply (Commodity &commodity)
 
 SupplyDemandManager (Agent *agent=NULL)
 
void UnregisterProducerManager (CommodityProducerManager *cpm)
 
virtual ~SupplyDemandManager ()
 
- Public Member Functions inherited from cyclus::toolkit::AgentManaged
Agentagent () const
 
 AgentManaged (Agent *agent=NULL)
 

Constructor & Destructor Documentation

cyclus::toolkit::SupplyDemandManager::SupplyDemandManager ( Agent agent = NULL)
inline

Definition at line 25 of file supply_demand_manager.h.

virtual cyclus::toolkit::SupplyDemandManager::~SupplyDemandManager ( )
inlinevirtual

Definition at line 26 of file supply_demand_manager.h.

Member Function Documentation

double cyclus::toolkit::SupplyDemandManager::Demand ( Commodity commodity,
int  time 
)
inline

The demand for a commodity at a given time.

Parameters
commoditythe commodity
timethe time

Definition at line 57 of file supply_demand_manager.h.

SymFunction::Ptr cyclus::toolkit::SupplyDemandManager::DemandFunction ( Commodity commodity)
inline

Returns the demand function for a commodity.

Parameters
commoditythe commodity being queried

Definition at line 63 of file supply_demand_manager.h.

bool cyclus::toolkit::SupplyDemandManager::ManagesCommodity ( Commodity commodity)
inline
Returns
true if the demand for a commodity is managed by this entity
Parameters
commoditythe commodity in question

Definition at line 39 of file supply_demand_manager.h.

void cyclus::toolkit::SupplyDemandManager::RegisterCommodity ( Commodity commodity,
SymFunction::Ptr  demand 
)
inline

Register a new commodity with the manager, along with all the necessary information.

Parameters
commoditythe commodity
demanda smart pointer to the demand function

Definition at line 32 of file supply_demand_manager.h.

void cyclus::toolkit::SupplyDemandManager::RegisterProducerManager ( CommodityProducerManager cpm)
inline

Adds a commodity producer manager to the set of producer managers.

Definition at line 44 of file supply_demand_manager.h.

double cyclus::toolkit::SupplyDemandManager::Supply ( Commodity commodity)

Returns the current supply of a commodity.

Parameters
commoditythe commodity
Returns
the current supply of the commodity

Definition at line 9 of file supply_demand_manager.cc.

void cyclus::toolkit::SupplyDemandManager::UnregisterProducerManager ( CommodityProducerManager cpm)
inline

Removes a commodity producer manager from the set of producer managers.

Definition at line 50 of file supply_demand_manager.h.


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