MythTV
master
programs
mythbackend
servicesv2
v2encoderList.h
Go to the documentation of this file.
1
// Program Name: encoderList.h
3
// Created : Jan. 15, 2010
4
//
5
// Copyright (c) 2010 David Blain <dblain@mythtv.org>
6
//
7
// Licensed under the GPL v2 or later, see COPYING for details
8
//
10
11
#ifndef V2ENCODERLIST_H_
12
#define V2ENCODERLIST_H_
13
14
#include <QVariantList>
15
16
#include "
libmythbase/http/mythhttpservice.h
"
17
18
#include "
v2encoder.h
"
19
20
class
V2EncoderList
:
public
QObject
21
{
22
Q_OBJECT
23
Q_CLASSINFO
(
"Version"
,
"1.0"
);
24
25
// Q_CLASSINFO Used to augment Metadata for properties.
26
// See datacontracthelper.h for details
27
28
Q_CLASSINFO
(
"Encoders"
,
"type=V2Encoder"
);
29
30
SERVICE_PROPERTY2
( QVariantList,
Encoders
);
31
32
public
:
33
34
Q_INVOKABLE
V2EncoderList
(QObject *parent =
nullptr
)
35
: QObject( parent )
36
{
37
}
38
39
void
Copy
(
const
V2EncoderList
*src )
40
{
41
CopyListContents< V2Encoder >(
this
, m_Encoders, src->m_Encoders );
42
}
43
// This is needed so that common routines can get a non-const m_Encoders
44
// reference
45
QVariantList&
GetEncoders
() {
return
m_Encoders;}
46
V2Encoder
*
AddNewEncoder
()
47
{
48
// We must make sure the object added to the QVariantList has
49
// a parent of 'this'
50
51
auto
*pObject =
new
V2Encoder
(
this
);
52
m_Encoders.append( QVariant::fromValue<QObject *>( pObject ));
53
54
return
pObject;
55
}
56
57
private
:
58
Q_DISABLE_COPY
(
V2EncoderList
);
59
};
60
61
Q_DECLARE_METATYPE
(
V2EncoderList
*)
62
63
#endif
V2EncoderList::AddNewEncoder
V2Encoder * AddNewEncoder()
Definition:
v2encoderList.h:46
V2EncoderList
Definition:
v2encoderList.h:20
V2EncoderList::Q_CLASSINFO
Q_CLASSINFO("Version", "1.0")
Q_DECLARE_METATYPE
Q_DECLARE_METATYPE(StandardSetting *)
V2EncoderList::V2EncoderList
Q_INVOKABLE V2EncoderList(QObject *parent=nullptr)
Definition:
v2encoderList.h:34
V2EncoderList::Q_DISABLE_COPY
Q_DISABLE_COPY(V2EncoderList)
v2encoder.h
V2EncoderList::Copy
void Copy(const V2EncoderList *src)
Definition:
v2encoderList.h:39
V2Encoder
Definition:
v2encoder.h:23
mythhttpservice.h
V2EncoderList::GetEncoders
QVariantList & GetEncoders()
Definition:
v2encoderList.h:45
V2EncoderList::SERVICE_PROPERTY2
SERVICE_PROPERTY2(QVariantList, Encoders)
Encoders
std::vector< uint32_t > Encoders
Definition:
mythdrmconnector.h:9
Generated on Sat May 27 2023 03:21:55 for MythTV by
1.8.17