You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
AppFlow/FITK_Component/FITKOFDictWriter/FITKOFTransportPropertiesWr...

108 lines
2.8 KiB
C

/**********************************************************************
* @file FITKOFTransportPropertiesWrite.h
* @brief TransportProperties
* @author liuzhonghua (liuzhonghuaszch@163.com)
* @date 2024-08-27
*********************************************************************/
#ifndef __FITKFLOWOFTRANSPORTPROPWRITER_H__
#define __FITKFLOWOFTRANSPORTPROPWRITER_H__
#include "FITKOFDictWriterAPI.h"
#include "FITKOFAbstractDictWriter.h"
namespace Interface
{
class FITKOFTransportPhase;
class FITKOFTransportProp;
}
namespace DICT
{
class FITKDictVector;
class FITKDictArray;
class FITKDictGroup;
}
namespace Core
{
class FITKAbstractEasyParam;
}
namespace IO
{
/**
* @brief ControlMeshDict
* @author liuzhonghua (liuzhonghuaszch@163.com)
* @date 2024-07-15
*/
class FITKOFTransportPropertiesWrite : public FITKOFAbstractDictWriter
{
public:
explicit FITKOFTransportPropertiesWrite();
virtual ~FITKOFTransportPropertiesWrite();
/**
* @brief
* @param[i] filePath
* @author liuzhonghua (liuzhonghuaszch@163.com)
* @date 2024-07-19
*/
void setFilePath(const QString& filePath) override;
/**
* @brief run
* @return true: false:
* @author liuzhonghua (liuzhonghuaszch@163.com)
* @date 2024-07-15
*/
bool run() override;
/**
* @brief
* @return QString
* @author liuzhonghua (liuzhonghuaszch@163.com)
* @date 2024-07-19
*/
QString getFileName() override;
private:
/**
* @brief FoamFile
* @author liuzhonghua (liuzhonghuaszch@163.com)
* @date 2024-07-19
*/
void dictObjectFoamFile(QString name = QString());
bool writePhasesFile(Interface::FITKOFTransportProp* transportData);
bool transportPropW(Interface::FITKOFTransportProp* transportData);
bool phaseOneW(Interface::FITKOFTransportPhase* phase, DICT::FITKDictGroup* group = nullptr);
/**
* @brief
* @param[i] para
* @param[o] key
* @param[o] value
* @param[i] ok
* @return bool
* @author liuzhonghua (liuzhonghuaszch@163.com)
* @date 2024-09-04
*/
bool getPara(Core::FITKAbstractEasyParam* para, QString& key, QString& value, bool ok = true);
QString getVName(QString vName);
QString getUnit(QString unit);
private:
/**
* @brief
* @author liuzhonghua (liuzhonghuaszch@163.com)
* @date 2024-07-19
*/
QString m_fileName{};
};
}
#endif