MythTV
master
programs
mythbackend
servicesv2
v2recRuleFilterList.h
Go to the documentation of this file.
1
2
#ifndef V2RECRULEFILTERLIST_H_
3
#define V2RECRULEFILTERLIST_H_
4
5
#include <QVariantList>
6
#include <QDateTime>
7
8
#include "
libmythbase/http/mythhttpservice.h
"
9
10
#include "
v2recRuleFilter.h
"
11
12
class
V2RecRuleFilterList
:
public
QObject
13
{
14
Q_OBJECT
15
Q_CLASSINFO
(
"Version"
,
"1.0"
);
16
17
// Q_CLASSINFO Used to augment Metadata for properties.
18
// See datacontracthelper.h for details
19
20
Q_CLASSINFO
(
"RecRuleFilters"
,
"type=V2RecRuleFilter"
);
21
Q_CLASSINFO
(
"AsOf"
,
"transient=true"
);
22
23
SERVICE_PROPERTY2
(
int
, StartIndex )
24
SERVICE_PROPERTY2
(
int
, Count )
25
SERVICE_PROPERTY2
(
int
, TotalAvailable )
26
SERVICE_PROPERTY2
( QDateTime , AsOf )
27
SERVICE_PROPERTY2
( QString , Version )
28
SERVICE_PROPERTY2
( QString , ProtoVer )
29
SERVICE_PROPERTY2
( QVariantList, RecRuleFilters );
30
31
public
:
32
33
Q_INVOKABLE
V2RecRuleFilterList
(QObject *parent =
nullptr
)
34
: QObject( parent )
35
{
36
}
37
38
void
Copy
(
const
V2RecRuleFilterList
*src )
39
{
40
m_AsOf = src->m_AsOf ;
41
m_Version = src->m_Version ;
42
m_ProtoVer = src->m_ProtoVer ;
43
44
CopyListContents< V2RecRuleFilter >(
this
, m_RecRuleFilters, src->m_RecRuleFilters );
45
}
46
47
V2RecRuleFilter
*
AddNewRecRuleFilter
()
48
{
49
// We must make sure the object added to the QVariantList has
50
// a parent of 'this'
51
52
auto
*pObject =
new
V2RecRuleFilter
(
this
);
53
m_RecRuleFilters.append( QVariant::fromValue<QObject *>( pObject ));
54
55
return
pObject;
56
}
57
58
private
:
59
Q_DISABLE_COPY
(
V2RecRuleFilterList
);
60
};
61
62
Q_DECLARE_METATYPE
(
V2RecRuleFilterList
*)
63
64
#endif
V2RecRuleFilterList::Q_DISABLE_COPY
Q_DISABLE_COPY(V2RecRuleFilterList)
V2RecRuleFilterList::AddNewRecRuleFilter
V2RecRuleFilter * AddNewRecRuleFilter()
Definition:
v2recRuleFilterList.h:47
Q_DECLARE_METATYPE
Q_DECLARE_METATYPE(StandardSetting *)
v2recRuleFilter.h
V2RecRuleFilterList::V2RecRuleFilterList
Q_INVOKABLE V2RecRuleFilterList(QObject *parent=nullptr)
Definition:
v2recRuleFilterList.h:33
V2RecRuleFilterList
Definition:
v2recRuleFilterList.h:12
V2RecRuleFilterList::Q_CLASSINFO
Q_CLASSINFO("Version", "1.0")
mythhttpservice.h
V2RecRuleFilterList::Copy
void Copy(const V2RecRuleFilterList *src)
Definition:
v2recRuleFilterList.h:38
V2RecRuleFilter
Definition:
v2recRuleFilter.h:12
V2RecRuleFilterList::SERVICE_PROPERTY2
SERVICE_PROPERTY2(QVariantList, RecRuleFilters)
Generated on Sat May 27 2023 03:21:55 for MythTV by
1.8.17