MythTV  master
channelGroup.h
Go to the documentation of this file.
1 // Program Name: channelGroup.h
3 // Created : Nov. 15, 2013
4 //
5 // Copyright (c) 2013 Stuart Morgan <smorgan@mythtv.org>
6 //
7 // Licensed under the GPL v2 or later, see LICENSE for details
8 //
10 
11 #ifndef DTCCHANNELGROUP_H_
12 #define DTCCHANNELGROUP_H_
13 
14 #include <QObject>
15 #include <QString>
16 
19 
20 namespace DTC
21 {
22 
23 class SERVICE_PUBLIC ChannelGroup : public QObject
24 {
25  Q_OBJECT
26  Q_CLASSINFO( "version", "0.99" );
27 
28  // Q_CLASSINFO Used to augment Metadata for properties.
29  // See datacontracthelper.h for details
30 
31  Q_PROPERTY( uint GroupId READ GroupId WRITE setGroupId )
32  Q_PROPERTY( QString Name READ Name WRITE setName )
33  Q_PROPERTY( QString Password READ Password WRITE setPassword )
34 
35  PROPERTYIMP ( uint , GroupId )
36  PROPERTYIMP_REF ( QString , Name )
37  PROPERTYIMP_REF ( QString , Password );
38 
39  public:
40 
41  static void InitializeCustomTypes();
42 
43  Q_INVOKABLE ChannelGroup(QObject *parent = nullptr)
44  : QObject ( parent ),
45  m_GroupId ( 0 )
46  {
47  }
48 
49  void Copy( const ChannelGroup *src )
50  {
51  m_GroupId = src->m_GroupId ;
52  m_Name = src->m_Name ;
53  m_Password = src->m_Password ;
54  }
55 
56  private:
57  Q_DISABLE_COPY(ChannelGroup);
58 };
59 
61 {
62  qRegisterMetaType< ChannelGroup* >();
63 }
64 
65 }
66 
67 #endif
Password
static StandardSetting * Password(bool enabled)
Setting for changing password.
Definition: galleryconfig.cpp:245
DTC::ChannelGroup::InitializeCustomTypes
static void InitializeCustomTypes()
Definition: channelGroup.h:60
SERVICE_PUBLIC
#define SERVICE_PUBLIC
Definition: serviceexp.h:9
datacontracthelper.h
serviceexp.h
DTC::ChannelGroup::Copy
void Copy(const ChannelGroup *src)
Definition: channelGroup.h:49
uint
unsigned int uint
Definition: compat.h:81
DTC::ChannelGroup
Definition: channelGroup.h:23
PROPERTYIMP
#define PROPERTYIMP(type, name)
Definition: datacontracthelper.h:56
Name
Definition: channelsettings.cpp:71
DTC
Definition: datacontracthelper.h:123
PROPERTYIMP_REF
#define PROPERTYIMP_REF(type, name)
Definition: datacontracthelper.h:70