|
|
|
@ -34,6 +34,31 @@ void CFDStructDataSolverReferenceQuantityManager::saveDataToDom(rapidjson::Docum
|
|
|
|
|
jsonAdd(dom, m_TorqueCenterOfMoment, {"region", 0, "refValue", "jx"});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void CFDStructDataSolverReferenceQuantityManager::readDataFromDom(rapidjson::Document &dom) {
|
|
|
|
|
QVariant temp;
|
|
|
|
|
|
|
|
|
|
jsonRead(dom, temp, {"region", 0, "refValue", "pressure"});
|
|
|
|
|
if (temp != QVariant()) {
|
|
|
|
|
m_Pressure = temp.toDouble();
|
|
|
|
|
}
|
|
|
|
|
jsonRead(dom, temp, {"region", 0, "refValue", "temperature"});
|
|
|
|
|
if (temp != QVariant()) {
|
|
|
|
|
m_Temperature = temp.toDouble();
|
|
|
|
|
}
|
|
|
|
|
jsonRead(dom, temp, {"region", 0, "refValue", "refLength"});
|
|
|
|
|
if (temp != QVariant()) {
|
|
|
|
|
m_Length = temp.toDouble();
|
|
|
|
|
}
|
|
|
|
|
jsonRead(dom, temp, {"region", 0, "refValue", "refArea"});
|
|
|
|
|
if (temp != QVariant()) {
|
|
|
|
|
m_Area = temp.toDouble();
|
|
|
|
|
}
|
|
|
|
|
jsonRead(dom, temp, {"region", 0, "refValue", "jx"});
|
|
|
|
|
if (temp != QVariant()) {
|
|
|
|
|
m_TorqueCenterOfMoment = temp.toString();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
CUIConfig *CFDStructDataSolverReferenceQuantityManager::genUIConfig() {
|
|
|
|
|
return new CUIConfig({
|
|
|
|
|
{"type", "Widget"},
|
|
|
|
|