00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00021
00022 #ifndef CONTENT_H
00023 #define CONTENT_H
00024
00025 #include <QScriptEngine>
00026
00027 #include "services/contentServices.h"
00028
00029 class Content : public ContentServices
00030 {
00031 Q_OBJECT
00032
00033 public:
00034
00035 Q_INVOKABLE Content( QObject *parent = 0 ) {}
00036
00037 public:
00038
00039 QFileInfo GetFile ( const QString &StorageGroup,
00040 const QString &FileName );
00041
00042 QFileInfo GetImageFile ( const QString &StorageGroup,
00043 const QString &FileName,
00044 int Width, int Height );
00045
00046 QStringList GetFileList ( const QString &StorageGroup );
00047
00048 QFileInfo GetRecordingArtwork ( const QString &Type,
00049 const QString &Inetref,
00050 int Season, int Width,
00051 int Height);
00052
00053 DTC::ArtworkInfoList*
00054 GetRecordingArtworkList( int ChanId,
00055 const QDateTime &StartTime );
00056
00057 DTC::ArtworkInfoList*
00058 GetProgramArtworkList( const QString &Inetref,
00059 int Season );
00060
00061 QFileInfo GetVideoArtwork ( const QString &Type,
00062 int Id, int Width, int Height );
00063
00064 QFileInfo GetAlbumArt ( int Id, int Width, int Height );
00065
00066 QFileInfo GetPreviewImage ( int ChanId,
00067 const QDateTime &StartTime,
00068 int Width,
00069 int Height,
00070 int SecsIn );
00071
00072 QFileInfo GetRecording ( int ChanId,
00073 const QDateTime &StartTime );
00074
00075 QFileInfo GetMusic ( int Id );
00076 QFileInfo GetVideo ( int Id );
00077
00078 QString GetHash ( const QString &storageGroup,
00079 const QString &FileName );
00080
00081 bool DownloadFile ( const QString &URL,
00082 const QString &StorageGroup );
00083
00084
00085 DTC::LiveStreamInfo *AddLiveStream ( const QString &StorageGroup,
00086 const QString &FileName,
00087 const QString &HostName,
00088 int MaxSegments,
00089 int Width,
00090 int Height,
00091 int Bitrate,
00092 int AudioBitrate,
00093 int SampleRate );
00094
00095 DTC::LiveStreamInfo *AddRecordingLiveStream ( int ChanId,
00096 const QDateTime &StartTime,
00097 int MaxSegments,
00098 int Width,
00099 int Height,
00100 int Bitrate,
00101 int AudioBitrate,
00102 int SampleRate );
00103
00104 DTC::LiveStreamInfo *AddVideoLiveStream ( int Id,
00105 int MaxSegments,
00106 int Width,
00107 int Height,
00108 int Bitrate,
00109 int AudioBitrate,
00110 int SampleRate );
00111
00112 DTC::LiveStreamInfo *GetLiveStream ( int Id );
00113 DTC::LiveStreamInfoList *GetLiveStreamList ( void );
00114 DTC::LiveStreamInfoList *GetFilteredLiveStreamList( const QString &FileName );
00115
00116 DTC::LiveStreamInfo *StopLiveStream ( int Id );
00117 bool RemoveLiveStream ( int Id );
00118 };
00119
00120 Q_SCRIPT_DECLARE_QMETAOBJECT( Content, QObject*);
00121
00122 #endif
00123
00124