#include <PostgresqlPlayLog.h>
Inheritance diagram for LiveSupport::Scheduler::PostgresqlPlayLog:
This object has to be configured with a simple empty element, as the following:
<postgresqlPlayLog/>
The DTD for the above element is:
<!ELEMENT postgresqlPlayLog EMPTY >
Definition at line 86 of file PostgresqlPlayLog.h.
Public Member Functions | |
PostgresqlPlayLog (Ptr< Db::ConnectionManagerInterface >::Ref cm) throw () | |
Construct a PostgresqlPlayLog. | |
virtual | ~PostgresqlPlayLog (void) throw () |
A virtual destructor, as this class has virtual functions. | |
virtual void | configure (const xmlpp::Element &element) throw (std::invalid_argument, std::logic_error) |
Configure the object based on the XML element supplied. | |
virtual Ptr< UniqueId >::Ref | addPlayLogEntry (Ptr< const UniqueId >::Ref audioClipId, Ptr< const ptime >::Ref timeStamp) throw (std::invalid_argument) |
Add a new entry to the play log. | |
virtual Ptr< std::vector< Ptr< PlayLogEntry >::Ref > >::Ref | getPlayLogEntries (Ptr< const ptime >::Ref fromTime, Ptr< const ptime >::Ref toTime) throw (std::invalid_argument) |
Return the list of play log entries for a specified time interval. | |
Static Public Member Functions | |
static const std::string | getConfigElementName (void) throw () |
Return the name of the XML element this object expects to be sent to a call to configure(). |
LiveSupport::Scheduler::PostgresqlPlayLog::PostgresqlPlayLog | ( | Ptr< Db::ConnectionManagerInterface >::Ref | cm | ) | throw () [inline] |
Construct a PostgresqlPlayLog.
cm | the connection manager the PostgresqlPlayLog will use to connect to the database. |
Definition at line 136 of file PostgresqlPlayLog.h.
virtual LiveSupport::Scheduler::PostgresqlPlayLog::~PostgresqlPlayLog | ( | void | ) | throw () [inline, virtual] |
A virtual destructor, as this class has virtual functions.
Definition at line 146 of file PostgresqlPlayLog.h.
Ptr< UniqueId >::Ref PostgresqlPlayLog::addPlayLogEntry | ( | Ptr< const UniqueId >::Ref | audioClipId, | |
Ptr< const ptime >::Ref | timeStamp | |||
) | throw (std::invalid_argument) [virtual] |
Add a new entry to the play log.
audioClipId | the audio clip played. | |
timeStamp | the time the clip was played (started). |
Implements LiveSupport::Scheduler::PlayLogInterface.
Definition at line 119 of file PostgresqlPlayLog.cxx.
void PostgresqlPlayLog::configure | ( | const xmlpp::Element & | element | ) | throw (std::invalid_argument, std::logic_error) [virtual] |
Configure the object based on the XML element supplied.
The supplied element is expected to be of the name returned by configElementName().
element | the XML element to configure the object from. |
std::invalid_argument | if the supplied XML element contains bad configuraiton information | |
std::logic_error | if the object has already been configured, and can not be reconfigured. |
Implements LiveSupport::Core::Configurable.
Definition at line 101 of file PostgresqlPlayLog.cxx.
static const std::string LiveSupport::Scheduler::PostgresqlPlayLog::getConfigElementName | ( | void | ) | throw () [inline, static] |
Return the name of the XML element this object expects to be sent to a call to configure().
Definition at line 157 of file PostgresqlPlayLog.h.
Referenced by LiveSupport::Scheduler::PlayLogFactory::configure().
Ptr< std::vector< Ptr< PlayLogEntry >::Ref > >::Ref PostgresqlPlayLog::getPlayLogEntries | ( | Ptr< const ptime >::Ref | fromTime, | |
Ptr< const ptime >::Ref | toTime | |||
) | throw (std::invalid_argument) [virtual] |
Return the list of play log entries for a specified time interval.
fromTime | the start of the time of the interval queried, inclusive | |
toTime | to end of the time of the interval queried, non-inclusive |
Implements LiveSupport::Scheduler::PlayLogInterface.
Definition at line 163 of file PostgresqlPlayLog.cxx.