-#include "LiveSupport/Core/Configurable.h"
+#include "LiveSupport/PlaylistExecutor/AudioPlayerInterface.h"
#include "AdviseSink.h"
#include "ErrorSink.h"
@@ -71,12 +71,27 @@ using namespace LiveSupport::Core;
/**
* A class to play audio files and SMIL files through the Helix
* Community Library.
+ * This class can be configured with the following XML element.
+ *
+ *
+ *
+ *
+ *
+ * where the dllPath is the path to the directory containing the Helix
+ * library shared objects.
+ *
+ * The DTD for the above configuration is the following:
+ *
+ *
+ *
+ *
+ *
*
* @author $Author: maroy $
- * @version $Revision: 1.1 $
+ * @version $Revision: 1.2 $
*/
-class HelixPlayer :
- virtual public Configurable
+class HelixPlayer : virtual public AudioPlayerInterface
{
friend void * eventHandlerThread(void *) throw();
@@ -131,6 +146,11 @@ class HelixPlayer :
*/
pthread_t eventHandlingThread;
+ /**
+ * Flag to indicate if this object has been initialized.
+ */
+ bool initialized;
+
/**
* Flag to mark if the event handling thread should be running
* and handling events.
@@ -149,12 +169,22 @@ class HelixPlayer :
public:
+ /**
+ * Constructor.
+ */
+ HelixPlayer(void) throw ()
+ {
+ playing = false;
+ initialized = false;
+ }
+
/**
* A virtual destructor, as this class has virtual functions.
*/
virtual
- ~HelixPlayer(void) throw ()
+ ~HelixPlayer(void) throw ()
{
+ deInitialize();
}
/**
@@ -196,7 +226,7 @@ class HelixPlayer :
* De-initialize the Helix Player object.
*/
virtual void
- deInitialize(void);
+ deInitialize(void) throw ();
/**
* Specify which audio resource to play.