PeriDyno
1.0.0
Loading...
Searching...
No Matches
D:
Peridyno
peridyno
src
Framework
Auxiliary
DebugInfo.cpp
Go to the documentation of this file.
1
#include "
DebugInfo.h
"
2
#include "
Log.h
"
3
4
#include <sstream>
5
6
namespace
dyno
7
{
8
void
DebugInfo::updateImpl
()
9
{
10
this->
print
();
11
}
12
13
PrintInt::PrintInt
()
14
{
15
this->varForceUpdate()->setValue(
true
);
16
}
17
18
void
PrintInt::print
()
19
{
20
std::ostringstream oss;
21
oss << this->inInt()->getData();
22
23
Log::sendMessage
(
Log::Info
, oss.str());
24
}
25
26
PrintUnsigned::PrintUnsigned
()
27
{
28
this->varForceUpdate()->setValue(
true
);
29
}
30
31
void
PrintUnsigned::print
()
32
{
33
std::ostringstream oss;
34
oss << this->inUnsigned()->getData();
35
36
Log::sendMessage
(
Log::Info
, oss.str());
37
}
38
39
PrintFloat::PrintFloat
()
40
{
41
this->varForceUpdate()->setValue(
true
);
42
}
43
44
void
PrintFloat::print
()
45
{
46
std::ostringstream oss;
47
oss << this->inFloat()->getData();
48
49
Log::sendMessage
(
Log::Info
, oss.str());
50
}
51
52
PrintVector::PrintVector
()
53
{
54
this->varForceUpdate()->setValue(
true
);
55
}
56
57
void
PrintVector::print
()
58
{
59
std::ostringstream oss;
60
auto
vec = this->inVector()->getData();
61
oss << vec.x <<
" "
<< vec.y <<
" "
<< vec.z;
62
63
Log::sendMessage
(
Log::Info
, oss.str());
64
}
65
}
DebugInfo.h
Log.h
dyno::DebugInfo::updateImpl
void updateImpl() final
Definition
DebugInfo.cpp:8
dyno::DebugInfo::print
virtual void print()=0
dyno::Log::Info
@ Info
Information to user.
Definition
Log.h:48
dyno::Log::sendMessage
static void sendMessage(MessageType type, const std::string &text)
Add a new message to log.
Definition
Log.cpp:41
dyno::PrintFloat::print
void print() override
Definition
DebugInfo.cpp:44
dyno::PrintFloat::PrintFloat
PrintFloat()
Definition
DebugInfo.cpp:39
dyno::PrintInt::PrintInt
PrintInt()
Definition
DebugInfo.cpp:13
dyno::PrintInt::print
void print() override
Definition
DebugInfo.cpp:18
dyno::PrintUnsigned::print
void print() override
Definition
DebugInfo.cpp:31
dyno::PrintUnsigned::PrintUnsigned
PrintUnsigned()
Definition
DebugInfo.cpp:26
dyno::PrintVector::print
void print() override
Definition
DebugInfo.cpp:57
dyno::PrintVector::PrintVector
PrintVector()
Definition
DebugInfo.cpp:52
dyno
This is an implementation of AdditiveCCD based on peridyno.
Definition
Array.h:25
Generated by
1.13.2