MythTV  master
titleInfo.h
Go to the documentation of this file.
1 // Program Name: titleInfo.h
3 // Created : June 14, 2013
4 //
5 // Copyright (c) 2013 Chris Pinkham <cpinkham@mythtv.org>
6 //
7 // Licensed under the GPL v2 or later, see LICENSE for details
8 //
10 
11 #ifndef TITLEINFO_H_
12 #define TITLEINFO_H_
13 
14 #include <QString>
15 
18 
19 namespace DTC
20 {
21 
23 
24 class SERVICE_PUBLIC TitleInfo : public QObject
25 {
26  Q_OBJECT
27  Q_CLASSINFO( "version" , "1.1" );
28 
29  Q_PROPERTY( QString Title READ Title WRITE setTitle )
30  Q_PROPERTY( QString Inetref READ Inetref WRITE setInetref )
31  Q_PROPERTY( int Count READ Count WRITE setCount )
32 
33  PROPERTYIMP_REF( QString , Title )
34  PROPERTYIMP_REF( QString , Inetref )
35  PROPERTYIMP ( int , Count );
36 
37  public:
38 
39  static inline void InitializeCustomTypes();
40 
41  Q_INVOKABLE TitleInfo(QObject *parent = nullptr)
42  : QObject ( parent ),
43  m_Count(0)
44  {
45  }
46 
47  void Copy( const TitleInfo *src )
48  {
49  m_Title = src->m_Title ;
50  m_Inetref = src->m_Inetref ;
51  m_Count = src->m_Count ;
52  }
53 
54  private:
55  Q_DISABLE_COPY(TitleInfo);
56 };
57 
59 {
60  qRegisterMetaType< TitleInfo* >();
61 }
62 
63 } // namespace DTC
64 
65 #endif
DTC::TitleInfo::InitializeCustomTypes
static void InitializeCustomTypes()
Definition: titleInfo.h:58
SERVICE_PUBLIC
#define SERVICE_PUBLIC
Definition: serviceexp.h:9
datacontracthelper.h
serviceexp.h
DTC::TitleInfo
Definition: titleInfo.h:24
PROPERTYIMP
#define PROPERTYIMP(type, name)
Definition: datacontracthelper.h:56
DTC
Definition: datacontracthelper.h:123
DTC::TitleInfo::Copy
void Copy(const TitleInfo *src)
Definition: titleInfo.h:47
PROPERTYIMP_REF
#define PROPERTYIMP_REF(type, name)
Definition: datacontracthelper.h:70