Files
qt6-migration-pipeline/Lts/Common/CodeGen/CppTopicGeneratorGrantlee.h
T

48 lines
1.5 KiB
C++
Executable File

#pragma once
#include "GeneratorGrantleeBase.h"
#include "StructBuilder.h"
#include "GrantleeWrappers.h"
#include "codegen_export.h"
namespace CodeGen
{
class CppTopicGeneratorGrantlee final : public GeneratorGrantleeBase
{
Q_OBJECT
public:
explicit CppTopicGeneratorGrantlee();
bool init(const XmlReader *reader, StructBuilder *structBuilder) override;
private:
bool initDataTopics();
bool getSpecialColumns(const CompleteTopicTypeInformation &tti,
QVector<IdlData> &keyColumns,
QVector<IdlData> &trColumns) const;
bool initFunctionTopics();
bool handleStruct(const FunctionTopic &ft,
FunctionTopicsWrapper *functionTopicsWrapper);
bool addRequesterRequestParams(const QString &request_name,
const CompleteTopicTypeInformation &request,
FunctionTopicWrapper *ftw);
bool addRequesterReplyParams(const QString &request_name,
const CompleteTopicTypeInformation &reply,
FunctionTopicWrapper *ftw);
bool handleIdlStruct(const CompleteTopicTypeInformation &csi,
QSet<QString> &idlStructNames,
QVector<IdlStructWrapper *> &idlStructs);
bool initIdlStructs();
CompleteTopicTypeInformation topicTypeInformationByDerivedTopic(const CompleteTopicTypeInformation &tti) const;
const XmlReader *m_reader = nullptr;
};
}