Accelerated Computation Engine
emetadata.h
1
#ifndef EMETADATA_H
2
#define EMETADATA_H
3
#include "global.h"
4
5
6
7
class
QString;
8
class
QByteArray;
9
class
QJsonValue;
10
//
11
12
13
22
class
EMetadata
23
{
24
public
:
25
friend
EDebug
&
operator<<
(
EDebug
& debug,
const
EMetadata
*
const
meta);
26
public
:
27
EMetadata
&
operator=
(
const
EMetadata
&
object
);
28
EMetadata
&
operator=
(
EMetadata
&&
object
);
29
public
:
33
enum
Type
34
{
38
Null
42
,
Bool
46
,
Double
50
,
String
55
,
Bytes
59
,
Array
64
,Object
65
};
66
EMetadata
(
Type
type
=
Null
);
67
EMetadata
(
double
value);
68
EMetadata
(
const
QString& value);
69
EMetadata
(
const
QByteArray& value);
70
EMetadata
(
const
EMetaArray
& value);
71
EMetadata
(
const
EMetaObject
& value);
72
EMetadata
(
const
QJsonValue& value);
73
EMetadata
(
const
EMetadata
&
object
);
74
EMetadata
(
EMetadata
&&
object
);
75
~EMetadata
();
76
QJsonValue
toJson
()
const
;
77
EMetadata::Type
type
()
const
;
78
bool
isNull
()
const
;
79
bool
isBool
()
const
;
80
bool
isDouble
()
const
;
81
bool
isString
()
const
;
82
bool
isBytes
()
const
;
83
bool
isArray
()
const
;
84
bool
isObject
()
const
;
85
const
bool
&
toBool
()
const
;
86
const
double
&
toDouble
()
const
;
87
const
QString&
toString
()
const
;
88
const
QByteArray&
toBytes
()
const
;
89
const
EMetaArray
&
toArray
()
const
;
90
const
EMetaObject
&
toObject
()
const
;
91
bool
&
toBool
();
92
double
&
toDouble
();
93
QString&
toString
();
94
QByteArray&
toBytes
();
95
EMetaArray
&
toArray
();
96
EMetaObject
&
toObject
();
97
static
QString
typeName
(
Type
type
);
98
private
:
99
void
checkType(
Type
type
)
const
;
100
void
clear();
101
void
create();
102
void
copy(
const
void
* data);
106
Type
_type;
110
void
* _data {
nullptr
};
111
};
112
113
114
115
#endif
EMetadata::toBytes
const QByteArray & toBytes() const
Definition:
emetadata.cpp:577
EMetadata::isNull
bool isNull() const
Definition:
emetadata.cpp:400
EMetadata::isString
bool isString() const
Definition:
emetadata.cpp:451
EMetadata::isArray
bool isArray() const
Definition:
emetadata.cpp:485
EMetadata::toArray
const EMetaArray & toArray() const
Definition:
emetadata.cpp:596
EMetaArray
Definition:
emetaarray.h:16
EMetadata::operator=
EMetadata & operator=(const EMetadata &object)
Definition:
emetadata.cpp:26
EMetadata::toDouble
const double & toDouble() const
Definition:
emetadata.cpp:539
EMetadata::toObject
const EMetaObject & toObject() const
Definition:
emetadata.cpp:615
EMetadata::toString
const QString & toString() const
Definition:
emetadata.cpp:558
EMetadata::EMetadata
EMetadata(Type type=Null)
Definition:
emetadata.cpp:83
EMetadata::toJson
QJsonValue toJson() const
Definition:
emetadata.cpp:325
EMetadata::Double
Definition:
emetadata.h:46
EMetadata::Array
Definition:
emetadata.h:59
EMetadata::type
EMetadata::Type type() const
Definition:
emetadata.cpp:383
EMetadata::isObject
bool isObject() const
Definition:
emetadata.cpp:502
EMetadata::typeName
static QString typeName(Type type)
Definition:
emetadata.cpp:749
EMetadata::String
Definition:
emetadata.h:50
EMetadata
Definition:
emetadata.h:22
EDebug
Definition:
edebug.h:38
EMetadata::Null
Definition:
emetadata.h:38
EMetadata::Type
Type
Definition:
emetadata.h:33
EMetaObject
Definition:
emetaobject.h:18
EMetadata::isDouble
bool isDouble() const
Definition:
emetadata.cpp:434
EMetadata::Bool
Definition:
emetadata.h:42
EMetadata::operator<<
friend EDebug & operator<<(EDebug &debug, const EMetadata *const meta)
Definition:
common.cpp:185
EMetadata::~EMetadata
~EMetadata()
Definition:
emetadata.cpp:305
EMetadata::toBool
const bool & toBool() const
Definition:
emetadata.cpp:520
EMetadata::isBytes
bool isBytes() const
Definition:
emetadata.cpp:468
EMetadata::Bytes
Definition:
emetadata.h:55
EMetadata::isBool
bool isBool() const
Definition:
emetadata.cpp:417
Generated by
1.8.14