#include <pool.h>
Inherits boost::noncopyable.
Public Types | |
typedef std::map< std::pair< string, annotation_t >, shared_ptr< annotated_commodity_t > > | annotated_commodities_map |
typedef std::map< string, shared_ptr< commodity_t > > | commodities_map |
The commodities collection in commodity_pool_t maintains pointers to all the commodities which have ever been created by the user, whether explicitly by calling the create methods of commodity_pool_t, or implicitly by parsing a commoditized amount. | |
Static Public Attributes | |
static shared_ptr< commodity_pool_t > | current_pool |
typedef std::map<std::pair<string, annotation_t>, shared_ptr<annotated_commodity_t> > ledger::commodity_pool_t::annotated_commodities_map |
typedef std::map<string, shared_ptr<commodity_t> > ledger::commodity_pool_t::commodities_map |
The commodities collection in commodity_pool_t maintains pointers to all the commodities which have ever been created by the user, whether explicitly by calling the create methods of commodity_pool_t, or implicitly by parsing a commoditized amount.
|
explicit |
|
inlinevirtual |
Definition at line 91 of file pool.h.
References TRACE_DTOR.
commodity_t * ledger::commodity_pool_t::alias | ( | const string & | name, |
commodity_t & | referent ) |
annotated_commodity_t * ledger::commodity_pool_t::create | ( | commodity_t & | comm, |
const annotation_t & | details ) |
commodity_t * ledger::commodity_pool_t::create | ( | const string & | symbol | ) |
commodity_t * ledger::commodity_pool_t::create | ( | const string & | symbol, |
const annotation_t & | details ) |
void ledger::commodity_pool_t::exchange | ( | commodity_t & | commodity, |
const amount_t & | per_unit_cost, | ||
const datetime_t & | moment ) |
cost_breakdown_t ledger::commodity_pool_t::exchange | ( | const amount_t & | amount, |
const amount_t & | cost, | ||
const bool | is_per_unit = false, | ||
const bool | add_price = true, | ||
const optional< datetime_t > & | moment = none, | ||
const optional< string > & | tag = none ) |
commodity_t * ledger::commodity_pool_t::find | ( | const string & | name | ) |
commodity_t * ledger::commodity_pool_t::find | ( | const string & | symbol, |
const annotation_t & | details ) |
commodity_t * ledger::commodity_pool_t::find_or_create | ( | commodity_t & | comm, |
const annotation_t & | details ) |
commodity_t * ledger::commodity_pool_t::find_or_create | ( | const string & | symbol | ) |
commodity_t * ledger::commodity_pool_t::find_or_create | ( | const string & | symbol, |
const annotation_t & | details ) |
optional< std::pair< commodity_t *, price_point_t > > ledger::commodity_pool_t::parse_price_directive | ( | char * | line, |
bool | do_not_add_price = false, | ||
bool | no_date = false ) |
commodity_t * ledger::commodity_pool_t::parse_price_expression | ( | const std::string & | str, |
const bool | add_prices = true, | ||
const optional< datetime_t > & | moment = none ) |
annotated_commodities_map ledger::commodity_pool_t::annotated_commodities |
commodities_map ledger::commodity_pool_t::commodities |
commodity_history_t ledger::commodity_pool_t::commodity_price_history |
|
static |
commodity_t* ledger::commodity_pool_t::default_commodity |
function<optional<price_point_t>(commodity_t& commodity, const commodity_t * in_terms_of) ledger::commodity_pool_t::get_commodity_quote) |
commodity_t* ledger::commodity_pool_t::null_commodity |