MythTV  master
storageGroupDir.h
Go to the documentation of this file.
1 #ifndef STORAGEGROUPDIR_H_
2 #define STORAGEGROUPDIR_H_
3 
4 #include <QString>
5 
8 
9 namespace DTC
10 {
11 
13 
14 class SERVICE_PUBLIC StorageGroupDir : public QObject
15 {
16  Q_OBJECT
17  Q_CLASSINFO( "version" , "1.1" );
18 
19  Q_PROPERTY( int Id READ Id WRITE setId )
20  Q_PROPERTY( QString GroupName READ GroupName WRITE setGroupName )
21  Q_PROPERTY( QString HostName READ HostName WRITE setHostName )
22  Q_PROPERTY( QString DirName READ DirName WRITE setDirName )
23  Q_PROPERTY( bool DirRead READ DirRead WRITE setDirRead )
24  Q_PROPERTY( bool DirWrite READ DirWrite WRITE setDirWrite )
25  Q_PROPERTY( uint KiBFree READ KiBFree WRITE setKiBFree )
26 
27  PROPERTYIMP ( int , Id )
28  PROPERTYIMP_REF( QString , GroupName )
29  PROPERTYIMP_REF( QString , HostName )
30  PROPERTYIMP_REF( QString , DirName )
31  PROPERTYIMP ( bool , DirRead )
32  PROPERTYIMP ( bool , DirWrite )
33  PROPERTYIMP ( uint , KiBFree );
34 
35  public:
36 
37  static inline void InitializeCustomTypes();
38 
39  Q_INVOKABLE StorageGroupDir(QObject *parent = nullptr)
40  : QObject ( parent ),
41  m_Id ( 0 ),
42  m_DirRead ( false ),
43  m_DirWrite ( false ),
44  m_KiBFree ( 0 )
45  {
46  }
47 
48  void Copy( const StorageGroupDir *src )
49  {
50  m_Id = src->m_Id ;
51  m_GroupName = src->m_GroupName ;
52  m_HostName = src->m_HostName ;
53  m_DirName = src->m_DirName ;
54  m_DirRead = src->m_DirRead ;
55  m_DirWrite = src->m_DirWrite ;
56  m_KiBFree = src->m_KiBFree ;
57  }
58 
59  private:
60  Q_DISABLE_COPY(StorageGroupDir);
61 };
62 
64 {
65  qRegisterMetaType< StorageGroupDir* >();
66 }
67 
68 } // namespace DTC
69 
70 #endif
DTC::StorageGroupDir::InitializeCustomTypes
static void InitializeCustomTypes()
Definition: storageGroupDir.h:63
false
VERBOSE_PREAMBLE false
Definition: verbosedefs.h:89
DTC::StorageGroupDir::Copy
void Copy(const StorageGroupDir *src)
Definition: storageGroupDir.h:48
SERVICE_PUBLIC
#define SERVICE_PUBLIC
Definition: serviceexp.h:9
DTC::StorageGroupDir
Definition: storageGroupDir.h:14
datacontracthelper.h
serviceexp.h
uint
unsigned int uint
Definition: compat.h:81
PROPERTYIMP
#define PROPERTYIMP(type, name)
Definition: datacontracthelper.h:56
DTC
Definition: datacontracthelper.h:123
PROPERTYIMP_REF
#define PROPERTYIMP_REF(type, name)
Definition: datacontracthelper.h:70