![]() |
RTBKit
0.9
Open-source framework to create real-time ad bidding systems.
|
#include <banker.h>
Public Types | |
typedef std::function< void(std::exception_ptr)> | OnBudgetResult |
Public Member Functions | |
virtual ShadowAccount | addSpendAccountSync (const AccountKey &account, CurrencyPool accountFloat=CurrencyPool()) |
virtual void | addSpendAccount (const AccountKey &account, CurrencyPool accountFloat, std::function< void(std::exception_ptr, ShadowAccount &&)> onDone) |
virtual bool | authorizeBid (const AccountKey &account, const std::string &item, Amount amount)=0 |
virtual void | cancelBid (const AccountKey &account, const std::string &item) |
virtual void | winBid (const AccountKey &account, const std::string &item, Amount amountPaid, const LineItems &lineItems=LineItems()) |
virtual void | attachBid (const AccountKey &account, const std::string &item, Amount amountAuthorized)=0 |
virtual Amount | detachBid (const AccountKey &account, const std::string &item)=0 |
virtual void | commitBid (const AccountKey &account, const std::string &item, Amount amountPaid, const LineItems &lineItems)=0 |
virtual void | forceWinBid (const AccountKey &account, Amount amountPaid, const LineItems &lineItems)=0 |
virtual void | sync () |
virtual void | logBidEvents (const Datacratic::EventRecorder &eventRecorder) |
Protected Member Functions | |
virtual void | sanityCheck (const std::string &campaign) const |
virtual void RTBKIT::Banker::commitBid | ( | const AccountKey & | account, |
const std::string & | item, | ||
Amount | amountPaid, | ||
const LineItems & | lineItems | ||
) | [pure virtual] |
Commit a bid. This is used internally to both cancel and win bids. Asynchonous and returns no value.
Implemented in RTBKIT::SlaveBanker, and RTBKIT::NullBanker.
virtual void RTBKIT::Banker::sync | ( | ) | [inline, virtual] |