blob: ea58bad8879b2adbde9822308fd903ffab7f522d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
#ifndef _EMACS_H
#define _EMACS_H
#include "journal.h"
#include "format.h"
namespace ledger {
class format_emacs_transactions : public item_handler<transaction_t>
{
protected:
std::ostream& out;
entry_t * last_entry;
public:
format_emacs_transactions(std::ostream& _out)
: out(_out), last_entry(NULL) {}
virtual void write_entry(entry_t& entry);
virtual void flush() {
if (last_entry)
out << "))\n";
out.flush();
}
virtual void operator()(transaction_t& xact);
};
} // namespace ledger
#endif // _REPORT_H
|