source: pacpusframework/trunk/include/Pacpus/DbitePlayer/DbtPlyEngineStateChart.h@ 76

Last change on this file since 76 was 76, checked in by Marek Kurdej, 11 years ago

Added: automated license updating lines:
%pacpus:license{
%pacpus:license}

  • Property svn:keywords set to Id
File size: 3.3 KB
RevLine 
[76]1// %pacpus:license{
[62]2// This file is part of the PACPUS framework distributed under the
3// CECILL-C License, Version 1.0.
[76]4// %pacpus:license}
[66]5/// @file
[62]6/// @author Elie Al Alam <firstname.surname@utc.fr>
7/// @author Gerald Dherbomez <firstname.surname@utc.fr>
8/// @author Marek Kurdej <firstname.surname@utc.fr>
9/// @date April, 2007
10/// @version $Id: DbtPlyEngineStateChart.h 76 2013-01-10 17:05:10Z kurdejma $
11/// @copyright Copyright (c) UTC/CNRS Heudiasyc 2006 - 2013. All rights reserved.
12/// @brief DbitePlayer state machine.
13///
14/// Detailed description.
[3]15
[31]16#ifndef DEF_PACPUS_DBTPLYENGINESTATECHART_H
17#define DEF_PACPUS_DBTPLYENGINESTATECHART_H
[3]18
[31]19#include <QString>
[3]20
[31]21#include <Pacpus/DbitePlayer/DbitePlayerConfig.h>
[3]22
23namespace pacpus {
24
25class DbtPlyEngine;
26
27////////////////////////////////////////////////////////////////////////////////
28class DBITE_PLAYER_API DbtPlyEngineState
29{
30public:
[53]31 /// @todo Documentation
[3]32 virtual ~DbtPlyEngineState();
[53]33
34 /// @todo Documentation
[3]35 virtual void play(DbtPlyEngine & engine);
[53]36 /// @todo Documentation
[3]37 virtual void pause(DbtPlyEngine & engine);
[53]38 /// @todo Documentation
[3]39 virtual void stop(DbtPlyEngine & engine);
[53]40
41 /// @todo Documentation
[3]42 virtual void speedUp(DbtPlyEngine & engine);
[53]43 /// @todo Documentation
[3]44 virtual void speedDown(DbtPlyEngine & engine);
[53]45
46 /// @todo Documentation
[3]47 virtual bool isPlaying();
[53]48
49 /// @todo Documentation
[3]50 virtual QString toString() const = 0;
51
52protected:
[53]53 /// @todo Documentation
[3]54 DbtPlyEngineState();
55};
56
57////////////////////////////////////////////////////////////////////////////////
58class DBITE_PLAYER_API PlayingState
59 : public DbtPlyEngineState
60{
61public:
[53]62 /// @todo Documentation
[3]63 virtual void pause(DbtPlyEngine & engine);
[53]64 /// @todo Documentation
[3]65 virtual void stop(DbtPlyEngine & engine);
[53]66
67 /// @todo Documentation
[3]68 virtual bool isPlaying();
[53]69
70 /// @todo Documentation
[3]71 virtual QString toString() const;
[53]72 /// @todo Documentation
[3]73 static DbtPlyEngineState * getInstance();
74
75private:
76 PlayingState();
77 static PlayingState mInstance;
78};
79
80////////////////////////////////////////////////////////////////////////////////
[69]81/// State class when player is on pause.
[3]82class DBITE_PLAYER_API PausedState
83 : public DbtPlyEngineState
84{
85public:
[53]86 /// @todo Documentation
[3]87 virtual void play(DbtPlyEngine & engine);
[53]88 /// @todo Documentation
[3]89 virtual void stop(DbtPlyEngine & engine);
[53]90
91 /// @todo Documentation
[3]92 virtual QString toString() const;
[53]93 /// @todo Documentation
[3]94 static DbtPlyEngineState * getInstance();
95
96private:
97 PausedState();
98 static PausedState mInstance;
99};
100
101////////////////////////////////////////////////////////////////////////////////
[69]102/// State class when player is stopped.
[3]103class DBITE_PLAYER_API StoppedState
104 : public DbtPlyEngineState
105{
106public:
[53]107 /// @todo Documentation
[3]108 virtual void play(DbtPlyEngine & engine);
[53]109
110 /// @todo Documentation
[3]111 virtual QString toString() const;
[53]112 /// @todo Documentation
[3]113 static DbtPlyEngineState * getInstance();
114
115private:
116 StoppedState();
117 static StoppedState mInstance;
118};
119
120} // namespace pacpus
121
[31]122#endif // DEF_PACPUS_DBTPLYENGINESTATECHART_H
Note: See TracBrowser for help on using the repository browser.