-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathProperty.cpp
More file actions
75 lines (72 loc) · 1.99 KB
/
Copy pathProperty.cpp
File metadata and controls
75 lines (72 loc) · 1.99 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
#pragma once
#include "Reflection/Property.hpp"
namespace sh::core::reflection
{
Property::Property(const Property& other) noexcept :
data(other.data),
pureTypeName(other.pureTypeName),
type(other.type),
name(other.name),
containerNestedLevel(other.containerNestedLevel),
containerElementType(other.containerElementType),
bConstProperty(other.bConstProperty),
bVisibleProperty(other.bVisibleProperty),
bNoSaveProperty(other.bNoSaveProperty),
isConst(other.isConst),
isPointer(other.isPointer),
isContainer(other.isContainer),
isSObject(other.isSObject),
isSObjectPointer(other.isSObjectPointer),
isSObjectPointerContainer(other.isSObjectPointerContainer),
isEnum(other.isEnum)
{
}
SH_CORE_API auto Property::operator==(const Property& other) -> bool
{
return type == other.type && isConst == other.isConst;
}
SH_CORE_API auto Property::operator==(const TypeInfo& type) -> bool
{
return this->type == type && isConst == type.isConst;
}
SH_CORE_API auto Property::operator!=(const Property& other) -> bool
{
return !operator==(other);
}
SH_CORE_API auto Property::operator!=(const TypeInfo& type) -> bool
{
return !operator==(type);
}
SH_CORE_API auto Property::GetName() const -> const core::Name&
{
return name;
}
SH_CORE_API auto Property::Begin(SObject& SObject) const -> PropertyIteratorT
{
return data->Begin(&SObject);
}
SH_CORE_API auto Property::Begin(const SObject& SObject) const -> ConstPropertyIteratorT
{
return data->Begin(&SObject);
}
SH_CORE_API auto Property::End(SObject& SObject) const -> PropertyIteratorT
{
return data->End(&SObject);
}
SH_CORE_API auto Property::End(const SObject& SObject) const -> ConstPropertyIteratorT
{
return data->End(&SObject);
}
SH_CORE_API auto Property::GetContainerNestedLevel() const -> uint32_t
{
return containerNestedLevel;
}
SH_CORE_API auto Property::ClearContainer(SObject& SObject) const -> bool
{
if (isContainer)
{
data->ClearContainer(&SObject);
}
return false;
}
}//namespace