Namespaces | |
namespace | flags |
namespace | python |
Enumerations | |
enum | format_type_t { FMT_WRITTEN , FMT_PRINTED , FMT_CUSTOM } |
enum | hash_type_t { NO_HASHES = 0 , HASH_SHA512 = 1 , HASH_SHA512_Half = 2 } |
enum | parse_flags_enum_t { PARSE_DEFAULT = 0x00 , PARSE_PARTIAL = 0x01 , PARSE_SINGLE = 0x02 , PARSE_NO_MIGRATE = 0x04 , PARSE_NO_REDUCE = 0x08 , PARSE_NO_ASSIGN = 0x10 , PARSE_NO_ANNOT = 0x20 , PARSE_OP_CONTEXT = 0x40 , PARSE_SOFT_FAIL = 0x80 } |
Variables | |
std::ostringstream | _ctxt_buffer |
std::ostringstream | _desc_buffer |
std::string | _init_file |
string | empty_string |
optional< datetime_t > | epoch |
date_time::weekdays | start_of_week |
const string | version |
typedef std::pair<mask_t, account_t *> ledger::account_mapping_t |
typedef std::list<account_mapping_t> ledger::account_mappings_t |
typedef std::map< string, account_t * > ledger::accounts_map |
typedef shared_ptr<item_handler<account_t> > ledger::acct_handler_ptr |
typedef std::list< auto_xact_t * > ledger::auto_xacts_list |
typedef gregorian::date ledger::date |
typedef gregorian::date_duration ledger::date_duration |
typedef boost::gregorian::date_iterator ledger::date_iterator_t |
typedef boost::gregorian::date ledger::date_t |
typedef boost::posix_time::ptime ledger::datetime_t |
typedef std::map<string, posts_list> ledger::deferred_posts_map_t |
typedef boost::filesystem::filesystem_error ledger::filesystem_error |
typedef boost::filesystem::ifstream ledger::ifstream |
typedef boost::filesystem::ofstream ledger::ofstream |
typedef boost::filesystem::path ledger::path |
typedef std::pair<mask_t, string> ledger::payee_alias_mapping_t |
typedef std::pair<string, string> ledger::payee_uuid_mapping_t |
typedef std::list< period_xact_t * > ledger::period_xacts_list |
typedef shared_ptr<item_handler<post_t> > ledger::post_handler_ptr |
typedef std::list< post_t * > ledger::posts_list |
typedef std::map<datetime_t, amount_t> ledger::price_map_t |
typedef posix_time::ptime ledger::ptime |
typedef posix_time::seconds ledger::seconds |
typedef std::string ledger::string |
typedef std::list<string> ledger::strings_list |
typedef std::multimap<string, expr_t::check_expr_pair> ledger::tag_check_exprs_map |
typedef ptime::time_duration_type ledger::time_duration |
typedef datetime_t::time_duration_type ledger::time_duration_t |
typedef std::list< xact_t * > ledger::xacts_list |
Definition at line 977 of file value.h.
References downcast().
|
inline |
Definition at line 225 of file annotate.h.
References downcast().
|
inline |
Definition at line 229 of file annotate.h.
References downcast().
expr_t::ptr_op_t ledger::as_expr | ( | const value_t & | val | ) |
sort_value_t ledger::calc_sort_value | ( | const expr_t::ptr_op_t | op | ) |
|
inline |
|
inline |
Definition at line 476 of file scope.h.
References ledger::value_t::ANY.
|
inline |
Definition at line 105 of file chain.h.
References chain_post_handlers(), and chain_pre_post_handlers().
post_handler_ptr ledger::chain_post_handlers | ( | post_handler_ptr | base_handler, |
report_t & | report, | ||
bool | for_accounts_report = false ) |
post_handler_ptr ledger::chain_pre_post_handlers | ( | post_handler_ptr | base_handler, |
report_t & | report ) |
optional< price_point_t > ledger::commodity_quote_from_script | ( | commodity_t & | commodity, |
const commodity_t * | exchange_commodity ) |
value_t ledger::convert_command | ( | call_scope_t & | scope | ) |
void ledger::debug_assert | ( | const string & | reason, |
const string & | func, | ||
const string & | file, | ||
std::size_t | line ) |
|
inline |
Definition at line 581 of file utils.h.
References downcast().
Referenced by sha1sum().
|
inline |
Definition at line 468 of file utils.h.
References downcast().
Referenced by ledger::balance_t::abs(), ledger::flags::supports_flags< T, U >::add_flags(), ledger::flags::delegates_flags< T >::add_flags(), add_or_set_value(), as_annotated_commodity(), as_annotated_commodity(), ledger::value_t::as_any(), ledger::value_t::as_any_lval(), ledger::expr_t::op_t::as_value_lval(), ledger::balance_t::balance_t(), ledger::balance_t::balance_t(), ledger::balance_t::balance_t(), ledger::flags::basic_t< T, U >::basic_t(), ledger::flags::basic_t< T, U >::basic_t(), ledger::date_range_t::begin(), ledger::date_specifier_or_range_t::begin(), ledger::date_interval_t::begin(), ledger::bind_scope_t::bind_scope_t(), ledger::expr_base_t< ResultType >::calc(), ledger::value_t::casted(), ledger::balance_t::ceilinged(), ledger::value_t::ceilinged(), ledger::truncate_xacts::clear(), ledger::sort_xacts::clear(), ledger::anonymize_posts::clear(), ledger::calc_posts::clear(), ledger::collapse_posts::clear(), ledger::changed_value_posts::clear(), ledger::posts_as_equity::clear(), ledger::day_of_week_posts::clear(), ledger::format_posts::clear(), ledger::post_t::clear_xdata(), ledger::python::register_optional_to_python< T >::optional_from_python::construct(), ledger::call_scope_t::context(), ledger::python::register_optional_to_python< T >::optional_from_python::convertible(), ledger::item_t::copy_details(), ledger::post_t::copy_details(), ledger::collapse_posts::create_accounts(), ledger::display_filter_posts::create_accounts(), ledger::changed_value_posts::create_accounts(), ledger::interval_posts::create_accounts(), ledger::posts_as_equity::create_accounts(), ledger::item_t::date(), ledger::date_specifier_t::date_specifier_t(), ledger::child_scope_t::define(), ledger::bind_scope_t::define(), ledger::option_t< T >::desc(), ledger::global_scope_t::description(), ledger::post_t::description(), ledger::report_t::description(), ledger::empty_scope_t::description(), ledger::session_t::description(), ledger::xact_t::description(), ledger::auto_xact_t::description(), ledger::period_xact_t::description(), digest_to_hex(), downcast(), ledger::flags::supports_flags< T, U >::drop_flags(), ledger::flags::delegates_flags< T >::drop_flags(), ledger::balance_t::dump(), ledger::format_t::dump(), either_or(), ledger::date_range_t::end(), ledger::date_specifier_or_range_t::end(), ledger::date_interval_t::end(), ledger::unistring::extract(), ledger::unistring::extract_by_width(), ledger::journal_t::fileinfo_t::fileinfo_t(), ledger::unistring::find(), find_scope(), find_scope(), ledger::balance_t::floored(), ledger::value_t::floored(), ledger::format_t::format_t(), ledger::query_t::get_query(), ledger::option_t< T >::handler(), ledger::flags::supports_flags< T, U >::has_flags(), ledger::flags::delegates_flags< T >::has_flags(), ledger::item_t::id(), ledger::date_specifier_t::implied_duration(), ledger::balance_t::in_place_reduce(), ledger::balance_t::in_place_roundto(), ledger::balance_t::in_place_unreduce(), ledger::date_interval_t::inclusive_end(), ledger::xact_posts_iterator::increment(), is_eq(), is_expr(), ledger::value_t::is_type(), is_valid(), is_valid(), ledger::date_range_t::is_within(), ledger::item_t::item_t(), join_args(), justify(), ledger::child_scope_t::lookup(), ledger::bind_scope_t::lookup(), ledger::value_scope_t::lookup(), ledger::empty_scope_t::lookup(), lowered(), ledger::format_t::mark_uncompiled(), ledger::report_t::maybe_format(), ledger::flags::basic_t< T, U >::minus_flags(), ledger::balance_t::negated(), ledger::value_t::negated(), ledger::expr_t::op_t::new_node(), next_element(), ledger::balance_t::number(), ledger::option_t< T >::off(), ledger::option_t< T >::on(), open_for_reading(), ledger::reporter< Type, handler_ptr, report_method >::operator()(), ledger::commodity_compare::operator()(), ledger::ComparePaths::operator()(), ledger::collect_posts::operator()(), ledger::push_to_posts_list::operator()(), ledger::sort_posts::operator()(), ledger::sort_xacts::operator()(), ledger::filter_posts::operator()(), ledger::related_posts::operator()(), ledger::day_of_week_posts::operator()(), ledger::item_handler< T >::operator()(), ledger::balance_t::operator*=(), ledger::balance_t::operator*=(), ledger::balance_t::operator*=(), ledger::balance_t::operator+=(), ledger::balance_t::operator+=(), ledger::balance_t::operator+=(), ledger::balance_t::operator-=(), ledger::balance_t::operator-=(), ledger::balance_t::operator-=(), ledger::balance_t::operator/=(), ledger::balance_t::operator/=(), ledger::balance_t::operator/=(), ledger::date_interval_t::operator<(), ledger::mask_t::operator<(), ledger::symbol_t::operator<(), ledger::value_t::operator<(), operator<<(), operator<<(), operator<<(), operator<<(), ledger::balance_t::operator=(), ledger::balance_t::operator=(), ledger::flags::basic_t< T, U >::operator=(), ledger::date_traits_t::operator=(), ledger::expr_base_t< ResultType >::operator=(), ledger::expr_base_t< ResultType >::operator=(), ledger::flags::supports_flags< T, U >::operator=(), ledger::flags::basic_t< T, U >::operator=(), ledger::expr_t::token_t::operator=(), ledger::query_t::lexer_t::token_t::operator=(), ledger::value_t::operator=(), ledger::balance_t::operator==(), ledger::balance_t::operator==(), ledger::commodity_t::operator==(), ledger::date_interval_t::operator==(), ledger::date_traits_t::operator==(), ledger::mask_t::operator==(), ledger::price_point_t::operator==(), ledger::symbol_t::operator==(), ledger::value_t::operator==(), ledger::balance_t::operator==(), ledger::value_t::operator>(), ledger::value_t::operator[](), ledger::value_t::operator[](), ledger::query_t::parser_t::parse(), ledger::expr_base_t< ResultType >::parse(), ledger::expr_base_t< ResultType >::parse(), ledger::query_t::parse_args(), ledger::format_t::parse_format(), ledger::commodity_t::parse_symbol(), ledger::auto_xact_t::parse_tags(), ledger::pass_down_accounts< Iterator >::pass_down_accounts(), ledger::pass_down_posts< Iterator >::pass_down_posts(), peek_next_nonws(), ledger::query_t::lexer_t::peek_token(), ledger::flags::basic_t< T, U >::plus_flags(), ledger::value_t::pop_back(), ledger::post_splitter::post_splitter(), ledger::post_t::post_t(), ledger::expr_base_t< ResultType >::preview(), ledger::ptristream::ptristream(), ledger::parse_context_stack_t::push(), ledger::parse_context_stack_t::push(), ledger::call_scope_t::push_back(), ledger::value_t::push_back(), ledger::call_scope_t::push_front(), ledger::value_t::push_front(), ledger::query_t::lexer_t::push_token(), put_date(), put_datetime(), put_mask(), ledger::query_t::query_t(), ledger::balance_t::reduced(), ledger::value_t::reduced(), ledger::python::register_python_conversion< T, TtoPy, TfromPy >::register_python_conversion(), ledger::report_t::report_format(), ledger::report_t::report_options(), ledger::session_t::report_options(), ledger::post_t::reported_account(), ledger::xacts_iterator::reset(), ledger::balance_t::rounded(), ledger::value_t::rounded(), ledger::balance_t::roundto(), ledger::value_t::roundto(), scope_value(), search_scope(), ledger::item_t::seq(), ledger::value_t::set_amount(), ledger::value_t::set_any(), ledger::value_t::set_any(), ledger::call_scope_t::set_args(), ledger::value_t::set_balance(), ledger::value_t::set_boolean(), ledger::value_t::set_date(), ledger::value_t::set_datetime(), ledger::flags::supports_flags< T, U >::set_flags(), ledger::flags::delegates_flags< T >::set_flags(), ledger::session_t::set_flush_on_next_data_file(), ledger::expr_t::op_t::set_function(), ledger::commodity_t::set_graph_index(), ledger::expr_t::op_t::set_ident(), ledger::commodity_t::set_larger(), ledger::value_t::set_long(), ledger::value_t::set_mask(), ledger::value_t::set_mask(), ledger::merged_expr_t::set_merge_operator(), ledger::commodity_t::set_name(), ledger::commodity_t::set_note(), ledger::post_splitter::set_postflush_func(), ledger::commodity_t::set_precision(), ledger::post_splitter::set_preflush_func(), ledger::value_t::set_scope(), ledger::expr_t::op_t::set_scope(), ledger::value_t::set_sequence(), ledger::commodity_t::set_smaller(), ledger::item_t::set_state(), ledger::value_t::set_string(), ledger::value_t::set_string(), ledger::merged_expr_t::set_term(), ledger::expr_base_t< ResultType >::set_text(), ledger::expr_t::op_t::set_value(), sha1sum(), ledger::global_scope_t::show_version_info(), ledger::value_t::simplified(), ledger::mask_t::str(), ledger::option_t< T >::str(), ledger::python::str_to_py_unicode(), ledger::balance_t::to_amount(), ledger::date_specifier_or_range_t::to_string(), to_string(), to_string(), ledger::query_t::parser_t::tokens_remaining(), trim_ws(), ledger::balance_t::truncated(), ledger::value_t::truncated(), ledger::unistring::unistring(), ledger::balance_t::unreduced(), ledger::value_t::unreduced(), ledger::balance_t::unrounded(), ledger::value_t::unrounded(), value_context(), ledger::value_t::value_t(), ledger::value_t::value_t(), ledger::value_t::value_t(), ledger::value_t::value_t(), ledger::value_t::value_t(), ledger::value_t::value_t(), ledger::value_t::value_t(), ledger::value_t::value_t(), ledger::value_t::value_t(), ledger::value_t::value_t(), ledger::value_t::value_t(), ledger::value_t::value_t(), ledger::value_t::value_t(), ledger::value_t::value_t(), ledger::report_t::what_to_keep(), ledger::expr_t::op_t::wrap_functor(), ledger::expr_t::op_t::wrap_value(), and ledger::xacts_iterator::xacts_iterator().
Definition at line 474 of file utils.h.
References downcast().
string ledger::error_context | ( | ) |
value_t ledger::eval_command | ( | call_scope_t & | args | ) |
value_t ledger::expr_value | ( | expr_t::ptr_op_t | op | ) |
|
inline |
Definition at line 222 of file scope.h.
References downcast(), ledger::child_scope_t::parent, and throw_.
|
inline |
Definition at line 234 of file scope.h.
References downcast(), and throw_.
value_t ledger::format_command | ( | call_scope_t & | args | ) |
std::string ledger::format_date | ( | const date_t & | when, |
const format_type_t | format_type = FMT_PRINTED, | ||
const optional< const char * > & | format = none ) |
std::string ledger::format_datetime | ( | const datetime_t & | when, |
const format_type_t | format_type = FMT_PRINTED, | ||
const optional< const char * > & | format = none ) |
Definition at line 232 of file option.h.
References downcast().
Dealing with expr pointers tucked into value objects.
Definition at line 113 of file expr.h.
References downcast().
Definition at line 63 of file times.h.
References downcast().
|
inline |
Definition at line 56 of file times.h.
References downcast().
Referenced by ledger::pass_down_posts< Iterator >::pass_down_posts().
|
inline |
Definition at line 568 of file scope.h.
References downcast(), and ledger::call_scope_t::size().
|
inline |
Definition at line 180 of file unistring.h.
References downcast().
string ledger::line_context | ( | const string & | line, |
const string::size_type | pos = 0, | ||
const string::size_type | end_pos = 0 ) |
std::pair< xact_t *, account_t * > ledger::lookup_probable_account | ( | const string & | ident, |
xacts_list::reverse_iterator | iter, | ||
xacts_list::reverse_iterator | end, | ||
account_t * | ref_account = NULL ) |
Definition at line 180 of file utils.h.
References downcast().
int ledger::mk_wcwidth | ( | boost::uint32_t | ucs | ) |
Referenced by ledger::unistring::extract_by_width(), and ledger::unistring::width().
Definition at line 493 of file utils.h.
References downcast(), and skip_ws().
string ledger::op_context | ( | const expr_t::ptr_op_t | op, |
const expr_t::ptr_op_t | locus = NULL ) |
|
inline |
Definition at line 115 of file context.h.
References downcast(), ledger::decrypted_stream_t::open_stream(), ledger::parse_context_t::pathname, resolve_path(), and throw_.
Referenced by ledger::parse_context_stack_t::push().
std::ostream & ledger::operator<< | ( | std::ostream & | out, |
const account_t & | account ) |
|
inline |
Definition at line 772 of file amount.h.
References ledger::amount_t::print(), ledger::amount_t::stream_fullstrings, and ledger::amount_t::unrounded().
|
inline |
Definition at line 151 of file annotate.h.
References ledger::annotation_t::print().
|
inline |
Definition at line 601 of file balance.h.
References downcast().
|
inline |
Definition at line 285 of file commodity.h.
References downcast().
std::ostream & ledger::operator<< | ( | std::ostream & | out, |
const date_duration_t & | duration ) |
std::ostream & ledger::operator<< | ( | std::ostream & | out, |
const expr_base_t< ResultType > & | expr ) |
Definition at line 236 of file exprbase.h.
References ledger::expr_base_t< ResultType >::print().
std::ostream & ledger::operator<< | ( | std::ostream & | out, |
const expr_t::token_t & | token ) |
std::ostream & ledger::operator<< | ( | std::ostream & | out, |
const expr_t::token_t::kind_t & | kind ) |
|
inline |
Definition at line 128 of file mask.h.
References downcast().
|
inline |
Definition at line 961 of file value.h.
References downcast().
|
inline |
Definition at line 779 of file amount.h.
References ledger::amount_t::parse().
value_t ledger::parse_command | ( | call_scope_t & | args | ) |
Definition at line 94 of file times.h.
References parse_date().
datetime_t ledger::parse_datetime | ( | const char * | str | ) |
|
inline |
Definition at line 88 of file times.h.
References parse_datetime().
|
inline |
Definition at line 514 of file utils.h.
References downcast().
value_t ledger::period_command | ( | call_scope_t & | args | ) |
strings_list ledger::process_arguments | ( | strings_list | args, |
scope_t & | scope ) |
bool ledger::process_option | ( | const string & | whence, |
const string & | name, | ||
scope_t & | scope, | ||
const char * | arg, | ||
const string & | varname ) |
void ledger::push_sort_value | ( | std::list< sort_value_t > & | sort_values, |
expr_t::ptr_op_t | node, | ||
scope_t & | scope ) |
void ledger::put_account | ( | property_tree::ptree & | pt, |
const account_t & | acct, | ||
function< bool(const account_t &)> | pred ) |
void ledger::put_amount | ( | property_tree::ptree & | pt, |
const amount_t & | amt, | ||
bool | commodity_details = false ) |
void ledger::put_annotation | ( | property_tree::ptree & | pt, |
const annotation_t & | details ) |
void ledger::put_commodity | ( | property_tree::ptree & | pt, |
const commodity_t & | comm, | ||
bool | commodity_details = false ) |
Definition at line 117 of file times.h.
References downcast(), FMT_WRITTEN, and format_date().
|
inline |
Definition at line 113 of file times.h.
References downcast(), FMT_WRITTEN, and format_datetime().
Definition at line 133 of file mask.h.
References downcast().
void ledger::put_metadata | ( | property_tree::ptree & | pt, |
const item_t::string_map & | metadata ) |
value_t ledger::query_command | ( | call_scope_t & | args | ) |
value_t ledger::report_statistics | ( | call_scope_t & | scope | ) |
Definition at line 972 of file value.h.
References downcast().
Referenced by ledger::report_t::fn_options().
T * ledger::search_scope | ( | scope_t * | ptr, |
bool | prefer_direct_parents = false ) |
Definition at line 201 of file scope.h.
References DEBUG, ledger::scope_t::description(), and downcast().
value_t ledger::select_command | ( | call_scope_t & | args | ) |
void ledger::set_expr | ( | value_t & | val, |
expr_t::ptr_op_t | op ) |
Set the current session context, transferring all static globals to point at the data structures related to this session.
Although Ledger itself is not thread-safe, by locking, switching session context, then unlocking after an operation is done, multiple threads can sequentially make use of the library. Thus, a session_t maintains all of the information relating to a single usage of the Ledger library.
|
inline |
Definition at line 603 of file utils.h.
References digest_to_hex(), and downcast().
Definition at line 479 of file utils.h.
Referenced by next_element(), and trim_ws().
bool ledger::sort_value_is_less_than | ( | const std::list< sort_value_t > & | left_values, |
const std::list< sort_value_t > & | right_values ) |
value_t ledger::source_command | ( | call_scope_t & | scope | ) |
string ledger::source_context | ( | const path & | file, |
const std::istream::pos_type | pos, | ||
const std::istream::pos_type | end_pos, | ||
const string & | prefix = "" ) |
strings_list ledger::split_arguments | ( | const char * | line | ) |
value_t ledger::split_cons_expr | ( | expr_t::ptr_op_t | op | ) |
Definition at line 949 of file value.h.
Referenced by ledger::option_t< T >::operator()(), and ledger::query_t::query_t().
value_t ledger::template_command | ( | call_scope_t & | args | ) |
Definition at line 49 of file error.h.
References _desc_buffer.
void ledger::times_initialize | ( | ) |
void ledger::times_shutdown | ( | ) |
Definition at line 168 of file utils.h.
References downcast().
|
inline |
Definition at line 174 of file utils.h.
References downcast().
Definition at line 485 of file utils.h.
References downcast(), and skip_ws().
Definition at line 966 of file value.h.
References downcast().
Definition at line 59 of file error.h.
References _desc_buffer.
Referenced by ledger::parse_context_t::warning(), and ledger::parse_context_t::warning().
value_t ledger::xact_command | ( | call_scope_t & | args | ) |
|
extern |
|
extern |
Referenced by throw_func(), and warning_func().
|
extern |
|
extern |
|
extern |
|
extern |