00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011 #ifndef PEEKABOT_CLIENT_RECORDING_IMPL_HH_INCLUDED
00012 #define PEEKABOT_CLIENT_RECORDING_IMPL_HH_INCLUDED
00013
00014
00015 #include "../PbarPlayer.hh"
00016
00017
00018 namespace peekabot
00019 {
00020 namespace client
00021 {
00022 class ClientImpl;
00023
00024 class RecordingImpl : public boost::noncopyable
00025 {
00026 public:
00027 RecordingImpl(
00028 ClientImpl &client,
00029 const std::string &filename);
00030
00031 void play();
00032
00033 void pause();
00034
00035 bool is_paused() const;
00036
00037 bool is_finished() const;
00038
00039 void step(size_t n);
00040
00041 void step(const boost::posix_time::time_duration &td);
00042
00043 void set_playback_speed(double factor);
00044
00045 double get_playback_speed() const;
00046
00047 boost::posix_time::time_duration elapsed() const;
00048
00049 boost::posix_time::time_duration duration() const;
00050
00051 private:
00052 void dispatch(boost::shared_ptr<Action> action);
00053
00054 private:
00055 ClientImpl &m_client;
00056
00057 PbarPlayer m_player;
00058 };
00059 }
00060 }
00061
00062
00063 #endif // PEEKABOT_CLIENT_RECORDING_IMPL_HH_INCLUDED