00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #ifndef KPLAYOBJECTFACTORY_H
00023 #define KPLAYOBJECTFACTORY_H
00024
00025 #include <kurl.h>
00026 #include "soundserver.h"
00027 #include "kplayobject.h"
00028
00029 class KPlayObjectFactory
00030 {
00031 public:
00032 KPlayObjectFactory(Arts::SoundServerV2 server);
00033 ~KPlayObjectFactory();
00034
00035 KPlayObject *createPlayObject(const KURL& url, bool createBUS);
00036 KPlayObject *createPlayObject(const KURL& url, const QString &mimetype, bool createBUS);
00037
00038 void setAllowStreaming(bool s) { m_allowStreaming = s; }
00039 bool allowStreaming() { return m_allowStreaming; }
00040
00041 bool isAStream() { return m_stream; }
00042
00043 private:
00044 Arts::SoundServerV2 m_server;
00045 bool m_allowStreaming;
00046 bool m_stream;
00047 };
00048
00049
00050 namespace KDE {
00051
00058 class PlayObjectFactory
00059 {
00060 public:
00065 PlayObjectFactory(Arts::SoundServerV2 server);
00066 ~PlayObjectFactory();
00067
00078 KDE::PlayObject *createPlayObject(const KURL& url, bool createBUS);
00079
00084 KDE::PlayObject *createPlayObject(const KURL& url, const QString &mimetype, bool createBUS);
00085
00091 void setAllowStreaming(bool s) { d->allowStreaming = s; }
00092
00097 bool allowStreaming() { return d->allowStreaming; }
00098
00102 static QStringList mimeTypes(void);
00103
00104 private:
00105 struct PrivateData {
00106 Arts::SoundServerV2 server;
00107 bool allowStreaming;
00108 bool isStream;
00109 };
00110 PrivateData* d;
00111 };
00112
00113 }
00114 #endif