mirror of https://github.com/qt/qtgrpc.git
Fix the generation of the export macro
Consider the EXPORT_MACRO CMake argument of qt_add_<protobuf|grpc>
calls.
Add the support for the EXPORT_MACRO option extras to the
qt<protobuf|grpc>gen generators. The extras now allow setting:
- export file name
- boolean flag that indicates if export file needs to be generated
The EXPORT_MACRO option of the generators now has the following format:
EXPORT_MACRO=<export_name>[:export_filename[:<true|false>]]
If export_filename is not set, then generators fall back to the previos
behavior and use the export_name as the export filename base, the file
will be generated unconditionally. If export_filename is set and the
follow boolean flag is not set or is set to false, generators skip the
generating of the export file.
[ChangeLog][Protobuf][qtprotobufgen] EXPORT_MACRO option now has the
following format:
EXPORT_MACRO=<export_name>[:export_filename[:<true|false>]]
New option extras allow setting the generated export filename and
control if it should be generated at the generator run.
[ChangeLog][GRPC][qtgrpcgen] EXPORT_MACRO option now has the
following format:
EXPORT_MACRO=<export_name>[:export_filename[:<true|false>]]
New option extras allow setting the generated export filename and
control if it should be generated at the generator run.
Pick-to: 6.7
Fixes: QTBUG-121854
Change-Id: Ifff6506ab363d18dc417f222e9929d7eba135d8a
Reviewed-by: Tatiana Borisova <tatiana.borisova@qt.io>
Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
This commit is contained in:
parent
d49d7df988
commit
ae2f1ed3d3
|
|
@ -148,15 +148,15 @@ function(qt6_add_grpc target type)
|
|||
message(FATAL_ERROR "Unsupported target type '${target_type}'.")
|
||||
endif()
|
||||
|
||||
if(is_static OR is_shared)
|
||||
# Add EXPORT_MACRO if the target is, or we will create, a shared library
|
||||
string(TOUPPER "${target}" target_upper)
|
||||
if (is_shared)
|
||||
list(APPEND generation_options "EXPORT_MACRO=${target_upper}")
|
||||
if(is_shared)
|
||||
set(generated_export "")
|
||||
set(generated_export_options "")
|
||||
_qt_internal_protoc_generate_cpp_exports(generated_export generated_export_options
|
||||
${target} "${arg_EXPORT_MACRO}")
|
||||
if(generated_export)
|
||||
list(APPEND cpp_sources "${generated_export}") # TODO: Unused, see QTBUG-121856
|
||||
endif()
|
||||
# Define this so we can conditionally set the export macro
|
||||
target_compile_definitions(${target}
|
||||
PRIVATE "QT_BUILD_${target_upper}_LIB")
|
||||
list(APPEND generation_options "${generated_export_options}")
|
||||
endif()
|
||||
|
||||
set(output_directory "${CMAKE_CURRENT_BINARY_DIR}")
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@ macro(_qt_internal_get_protoc_common_options option_args single_args multi_args)
|
|||
)
|
||||
set(${single_args}
|
||||
EXTRA_NAMESPACE
|
||||
EXPORT_MACRO
|
||||
QML_URI
|
||||
)
|
||||
|
||||
|
|
@ -27,6 +26,7 @@ macro(_qt_internal_get_protoc_generate_arguments option_args single_args multi_a
|
|||
PROTO_FILES_BASE_DIR
|
||||
OUTPUT_HEADERS
|
||||
OUTPUT_TARGETS
|
||||
EXPORT_MACRO
|
||||
)
|
||||
set(${multi_args}
|
||||
PROTO_FILES
|
||||
|
|
@ -241,6 +241,60 @@ function(_qt_internal_protobuf_package_qml_uri out_uri)
|
|||
set(${out_uri} ${qml_uri} PARENT_SCOPE)
|
||||
endfunction()
|
||||
|
||||
function(_qt_internal_protoc_generate_cpp_exports out_generated_file out_generation_options target
|
||||
export_macro)
|
||||
|
||||
# Add EXPORT_MACRO if the target is a shared library
|
||||
string(TOUPPER "${target}" target_upper)
|
||||
string(TOLOWER "${target}" target_lower)
|
||||
get_target_property(export_macro_previous ${target} _qt_internal_protobuf_export_macro)
|
||||
|
||||
# This is not the first time we enter this function for the target.
|
||||
if(export_macro_previous)
|
||||
if(export_macro AND NOT "${export_macro}" STREQUAL "${export_macro_previous}")
|
||||
message(FATAL_ERROR "EXPORT_MACRO argument doesn't match the one that already"
|
||||
"used for ${target}.\n"
|
||||
"Previous: ${export_macro_previous}\n"
|
||||
"New: ${export_macro}"
|
||||
)
|
||||
endif()
|
||||
set(export_macro "${export_macro_previous}")
|
||||
set(skip_generating TRUE)
|
||||
else()
|
||||
set(skip_generating FALSE)
|
||||
endif()
|
||||
|
||||
if(NOT export_macro)
|
||||
set(export_macro "${target_upper}")
|
||||
endif()
|
||||
|
||||
# Export filename is always based on target name.
|
||||
set(export_macro_filename "${target_lower}_exports.qpb.h")
|
||||
|
||||
if(skip_generating)
|
||||
# Tell the generator that we have export macro but we don't want to generate exports,
|
||||
# since they were generated in previous qt_add_<protobuf|grpc> call.
|
||||
set(${out_generation_options}
|
||||
"EXPORT_MACRO=${export_macro}:${export_macro_filename}:false")
|
||||
|
||||
# Avoid scheduling the file generating twice
|
||||
set(export_macro_filename "")
|
||||
else()
|
||||
set(${out_generation_options}
|
||||
"EXPORT_MACRO=${export_macro}:${export_macro_filename}:true")
|
||||
|
||||
set_target_properties(${target} PROPERTIES
|
||||
_qt_internal_protobuf_export_macro "${export_macro}")
|
||||
|
||||
# Define this so we can conditionally set the export macro behavior
|
||||
target_compile_definitions(${target}
|
||||
PRIVATE "QT_BUILD_${export_macro}_LIB")
|
||||
endif()
|
||||
|
||||
set(${out_generated_file} "${export_macro_filename}" PARENT_SCOPE)
|
||||
set(${out_generation_options} "${${out_generation_options}}" PARENT_SCOPE)
|
||||
endfunction()
|
||||
|
||||
# TODO Qt6:
|
||||
# - Collect PROTO_INCLUDES from the LINK_LIBRARIES property of TARGET
|
||||
# - Collect proto files from the source files of the ${TARGET}
|
||||
|
|
@ -422,32 +476,15 @@ function(qt6_add_protobuf target)
|
|||
message(FATAL_ERROR "Unsupported target type '${target_type}'.")
|
||||
endif()
|
||||
|
||||
if(is_static OR is_shared)
|
||||
# Add EXPORT_MACRO if the target is, or we will create, a shared library
|
||||
string(TOUPPER "${target}" target_upper)
|
||||
string(TOLOWER "${target}" target_lower)
|
||||
if (is_shared)
|
||||
list(APPEND generation_options "EXPORT_MACRO=${target_upper}")
|
||||
get_target_property(export_name ${target} _qt_internal_protobuf_export_file)
|
||||
if(NOT export_name)
|
||||
set(export_name "${output_directory}/${target_lower}_exports.qpb.h")
|
||||
get_property(existing_exports GLOBAL PROPERTY
|
||||
_qt_internal_existing_protobuf_exports)
|
||||
if("${export_name}" IN_LIST existing_exports)
|
||||
message(FATAL_ERROR "The export file ${export_name} is generated by multiple
|
||||
targets, which is prohibited, please make sure that you have unique target
|
||||
names.")
|
||||
endif()
|
||||
set_property(GLOBAL APPEND PROPERTY _qt_internal_existing_protobuf_exports
|
||||
"${export_name}")
|
||||
set_target_properties(${target} PROPERTIES _qt_internal_protobuf_export_file
|
||||
"${export_name}")
|
||||
list(APPEND cpp_sources ${export_name})
|
||||
endif()
|
||||
if(is_shared)
|
||||
set(generated_export "")
|
||||
set(generated_export_options "")
|
||||
_qt_internal_protoc_generate_cpp_exports(generated_export generated_export_options
|
||||
${target} "${arg_EXPORT_MACRO}")
|
||||
if(generated_export)
|
||||
list(APPEND cpp_sources "${output_directory}/${generated_export}")
|
||||
endif()
|
||||
# Define this so we can conditionally set the export macro
|
||||
target_compile_definitions(${target}
|
||||
PRIVATE "QT_BUILD_${target_upper}_LIB")
|
||||
list(APPEND generation_options "${generated_export_options}")
|
||||
endif()
|
||||
|
||||
_qt_internal_protoc_generate(${target} qtprotobufgen "${output_directory}"
|
||||
|
|
|
|||
|
|
@ -30,8 +30,6 @@ using namespace ::google::protobuf;
|
|||
using namespace ::google::protobuf::io;
|
||||
using namespace ::google::protobuf::compiler;
|
||||
|
||||
static std::string ExportStr("_exports.qpb");
|
||||
|
||||
QProtobufGenerator::QProtobufGenerator() : GeneratorBase()
|
||||
{}
|
||||
|
||||
|
|
@ -128,11 +126,15 @@ bool QProtobufGenerator::GenerateAll(const std::vector<const FileDescriptor *> &
|
|||
assert(generatorContext != nullptr);
|
||||
|
||||
Options::setFromString(parameter);
|
||||
if (!Options::instance().exportMacro().empty()) {
|
||||
if (Options::instance().generateMacroExportFile()) {
|
||||
std::string exportMacroName = Options::instance().exportMacro();
|
||||
utils::asciiToLower(exportMacroName);
|
||||
std::unique_ptr<io::ZeroCopyOutputStream> headerStream(
|
||||
generatorContext->Open(exportMacroName + ExportStr + ".h"));
|
||||
std::string exportMacroFilename = Options::instance().exportMacroFilename();
|
||||
|
||||
assert(!exportMacroName.empty());
|
||||
assert(!exportMacroFilename.empty());
|
||||
|
||||
std::unique_ptr<io::ZeroCopyOutputStream> headerStream(generatorContext
|
||||
->Open(exportMacroFilename));
|
||||
std::shared_ptr<Printer> headerPrinter(new Printer(headerStream.get(), '$'));
|
||||
printDisclaimer(headerPrinter.get());
|
||||
headerPrinter->Print({ { "export_macro", Options::instance().exportMacro() } },
|
||||
|
|
@ -165,10 +167,9 @@ void QProtobufGenerator::GenerateHeader(const FileDescriptor *file,
|
|||
fileNameToUpper.begin(), utils::toAsciiUpper);
|
||||
|
||||
headerPrinter->Print({{"filename", fileNameToUpper}}, CommonTemplates::PreambleTemplate());
|
||||
if (!Options::instance().exportMacro().empty()) {
|
||||
std::string exportMacroName = Options::instance().exportMacro();
|
||||
utils::asciiToLower(exportMacroName);
|
||||
internalIncludes.insert(exportMacroName + ExportStr);
|
||||
if (!Options::instance().exportMacroFilename().empty()) {
|
||||
std::string exportMacroFilename = Options::instance().exportMacroFilename();
|
||||
internalIncludes.insert(utils::removeFileSuffix(exportMacroFilename));
|
||||
}
|
||||
|
||||
headerPrinter->Print(CommonTemplates::DefaultProtobufIncludesTemplate());
|
||||
|
|
|
|||
|
|
@ -15,8 +15,10 @@ static const char FieldEnumGenerationOption[] = "FIELD_ENUM";
|
|||
static const char ExtraNamespaceGenerationOption[] = "EXTRA_NAMESPACE";
|
||||
static const char ExportMacroGenerationOption[] = "EXPORT_MACRO";
|
||||
|
||||
static const char ExportSuffix[] = "_exports.qpb.h";
|
||||
|
||||
Options::Options()
|
||||
: m_generateComments(false), m_isFolder(false), m_generateFieldEnum(true), m_qml(false)
|
||||
: m_generateComments(false), m_isFolder(false), m_generateFieldEnum(true), m_generateMacroExportFile(false), m_qml(false)
|
||||
{
|
||||
}
|
||||
|
||||
|
|
@ -65,8 +67,28 @@ void Options::setFromString(const std::string &options, GeneratorType type)
|
|||
instance.m_extraNamespace = extractCompositeOptionValue(option);
|
||||
QT_PROTOBUF_DEBUG("set m_extraNamespace: " << instance.m_extraNamespace);
|
||||
} else if (option.find(ExportMacroGenerationOption) == 0) {
|
||||
instance.m_exportMacro = extractCompositeOptionValue(option);
|
||||
QT_PROTOBUF_DEBUG("set m_exportMacro: " << instance.m_exportMacro);
|
||||
auto export_macro_values = utils::split(extractCompositeOptionValue(option), ":");
|
||||
if (!export_macro_values.empty()) {
|
||||
instance.m_exportMacro = export_macro_values[0];
|
||||
QT_PROTOBUF_DEBUG("set m_exportMacro: " << instance.m_exportMacro);
|
||||
if (export_macro_values.size() > 1) {
|
||||
instance.m_exportMacroFilename = export_macro_values[1];
|
||||
QT_PROTOBUF_DEBUG("set m_exportMacroFilename: "
|
||||
<< instance.m_exportMacroFilename);
|
||||
if (export_macro_values.size() > 2) {
|
||||
instance.m_generateMacroExportFile = export_macro_values[2] == "true";
|
||||
QT_PROTOBUF_DEBUG("set m_generateMacroExportFile: "
|
||||
<< instance.m_generateMacroExportFile);
|
||||
}
|
||||
}
|
||||
if (instance.m_exportMacroFilename.empty()) {
|
||||
std::string exportMacroLower = instance.m_exportMacro;
|
||||
utils::asciiToLower(exportMacroLower);
|
||||
instance.m_exportMacroFilename = exportMacroLower + ExportSuffix;
|
||||
QT_PROTOBUF_DEBUG("set m_exportMacroFilename: "
|
||||
<< instance.m_exportMacroFilename);
|
||||
}
|
||||
}
|
||||
} else if (option.find(QmlPluginUriOption) == 0 && type != QtGrpcGen) {
|
||||
instance.m_qmlUri = extractCompositeOptionValue(option);
|
||||
QT_PROTOBUF_DEBUG("set m_qmlUri: " << instance.m_qmlUri);
|
||||
|
|
|
|||
|
|
@ -39,6 +39,8 @@ public:
|
|||
bool generateFieldEnum() const { return m_generateFieldEnum; }
|
||||
const std::string &extraNamespace() const { return m_extraNamespace; }
|
||||
const std::string &exportMacro() const { return m_exportMacro; }
|
||||
const std::string &exportMacroFilename() const { return m_exportMacroFilename; }
|
||||
bool generateMacroExportFile() const { return m_generateMacroExportFile; }
|
||||
const std::string &qmlUri() const { return m_qmlUri; }
|
||||
|
||||
private:
|
||||
|
|
@ -47,6 +49,8 @@ private:
|
|||
bool m_generateFieldEnum;
|
||||
std::string m_extraNamespace;
|
||||
std::string m_exportMacro;
|
||||
std::string m_exportMacroFilename;
|
||||
bool m_generateMacroExportFile;
|
||||
std::string m_qmlUri;
|
||||
bool m_qml;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -25,14 +25,6 @@ qt_internal_add_test(tst_grpc_client_unarycall_qml
|
|||
Qt::Grpc
|
||||
)
|
||||
|
||||
qt_add_grpc(tst_grpc_client_unarycall_qml_gen CLIENT
|
||||
PROTO_FILES
|
||||
../../shared/data/proto/testservice.proto
|
||||
QML
|
||||
OUTPUT_DIRECTORY
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/qt_grpc_generated_qml"
|
||||
)
|
||||
|
||||
qt_add_protobuf(tst_grpc_client_unarycall_qml_gen
|
||||
PROTO_FILES
|
||||
../../shared/data/proto/testservice.proto
|
||||
|
|
@ -42,6 +34,14 @@ qt_add_protobuf(tst_grpc_client_unarycall_qml_gen
|
|||
"${CMAKE_CURRENT_BINARY_DIR}/qt_grpc_generated_qml"
|
||||
)
|
||||
|
||||
qt_add_grpc(tst_grpc_client_unarycall_qml_gen CLIENT
|
||||
PROTO_FILES
|
||||
../../shared/data/proto/testservice.proto
|
||||
QML
|
||||
OUTPUT_DIRECTORY
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/qt_grpc_generated_qml"
|
||||
)
|
||||
|
||||
qt_policy(SET QTP0001 NEW)
|
||||
|
||||
qt_add_qml_module(tst_grpc_client_unarycall_qml
|
||||
|
|
|
|||
|
|
@ -38,6 +38,7 @@ qt_add_protobuf(tst_qtprotobufgen
|
|||
OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/qt_protobuf_generated/extra-namespace"
|
||||
)
|
||||
|
||||
add_library(tst_qtprotobufgen_gen SHARED)
|
||||
qt_add_protobuf(tst_qtprotobufgen_gen
|
||||
PROTO_FILES
|
||||
../shared/data/proto/basicmessages.proto
|
||||
|
|
@ -50,6 +51,24 @@ qt_add_protobuf(tst_qtprotobufgen_gen
|
|||
)
|
||||
qt_autogen_tools_initial_setup(tst_qtprotobufgen_gen)
|
||||
|
||||
add_library(tst_qtprotobufgen_custom_exports_gen SHARED)
|
||||
qt_add_protobuf(tst_qtprotobufgen_custom_exports_gen
|
||||
PROTO_FILES
|
||||
../shared/data/proto/basicmessages.proto
|
||||
EXPORT_MACRO "CUSTOM_EXPORT_NAME"
|
||||
OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/qt_protobuf_generated/custom-exports"
|
||||
)
|
||||
qt_autogen_tools_initial_setup(tst_qtprotobufgen_custom_exports_gen)
|
||||
|
||||
add_library(tst_qtprotobufgen_no_exports_gen STATIC)
|
||||
qt_add_protobuf(tst_qtprotobufgen_no_exports_gen
|
||||
PROTO_FILES
|
||||
../shared/data/proto/basicmessages.proto
|
||||
EXPORT_MACRO "CUSTOM_EXPORT_NAME"
|
||||
OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/qt_protobuf_generated/no-exports"
|
||||
)
|
||||
qt_autogen_tools_initial_setup(tst_qtprotobufgen_no_exports_gen)
|
||||
|
||||
qt_add_protobuf(tst_qtprotobufgen
|
||||
PROTO_FILES
|
||||
../shared/data/proto/repeatednonpackedmessages.proto
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
|
|
@ -0,0 +1,738 @@
|
|||
/* This file is autogenerated. DO NOT CHANGE. All changes will be lost */
|
||||
|
||||
#ifndef QPROTOBUF_BASICMESSAGES_H
|
||||
#define QPROTOBUF_BASICMESSAGES_H
|
||||
|
||||
#include <QtProtobuf/qprotobufmessage.h>
|
||||
#include <QtProtobuf/qprotobufobject.h>
|
||||
#include <QtProtobuf/qprotobuflazymessagepointer.h>
|
||||
|
||||
#include <QtCore/qbytearray.h>
|
||||
#include <QtCore/qstring.h>
|
||||
#include "tst_qtprotobufgen_custom_exports_gen_exports.qpb.h"
|
||||
|
||||
#include <QtCore/qmetatype.h>
|
||||
#include <QtCore/qlist.h>
|
||||
#include <QtCore/qshareddata.h>
|
||||
|
||||
#include <memory>
|
||||
|
||||
|
||||
namespace qtprotobufnamespace::tests {
|
||||
class EmptyMessage;
|
||||
using EmptyMessageRepeated = QList<EmptyMessage>;
|
||||
namespace EmptyMessage_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace EmptyMessage_QtProtobufNested
|
||||
|
||||
class SimpleBoolMessage;
|
||||
using SimpleBoolMessageRepeated = QList<SimpleBoolMessage>;
|
||||
namespace SimpleBoolMessage_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleBoolMessage_QtProtobufNested
|
||||
|
||||
class SimpleIntMessage;
|
||||
using SimpleIntMessageRepeated = QList<SimpleIntMessage>;
|
||||
namespace SimpleIntMessage_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleIntMessage_QtProtobufNested
|
||||
|
||||
class SimpleSIntMessage;
|
||||
using SimpleSIntMessageRepeated = QList<SimpleSIntMessage>;
|
||||
namespace SimpleSIntMessage_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleSIntMessage_QtProtobufNested
|
||||
|
||||
class SimpleUIntMessage;
|
||||
using SimpleUIntMessageRepeated = QList<SimpleUIntMessage>;
|
||||
namespace SimpleUIntMessage_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleUIntMessage_QtProtobufNested
|
||||
|
||||
class SimpleInt64Message;
|
||||
using SimpleInt64MessageRepeated = QList<SimpleInt64Message>;
|
||||
namespace SimpleInt64Message_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleInt64Message_QtProtobufNested
|
||||
|
||||
class SimpleSInt64Message;
|
||||
using SimpleSInt64MessageRepeated = QList<SimpleSInt64Message>;
|
||||
namespace SimpleSInt64Message_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleSInt64Message_QtProtobufNested
|
||||
|
||||
class SimpleUInt64Message;
|
||||
using SimpleUInt64MessageRepeated = QList<SimpleUInt64Message>;
|
||||
namespace SimpleUInt64Message_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleUInt64Message_QtProtobufNested
|
||||
|
||||
class SimpleStringMessage;
|
||||
using SimpleStringMessageRepeated = QList<SimpleStringMessage>;
|
||||
namespace SimpleStringMessage_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleStringMessage_QtProtobufNested
|
||||
|
||||
class SimpleFloatMessage;
|
||||
using SimpleFloatMessageRepeated = QList<SimpleFloatMessage>;
|
||||
namespace SimpleFloatMessage_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleFloatMessage_QtProtobufNested
|
||||
|
||||
class SimpleDoubleMessage;
|
||||
using SimpleDoubleMessageRepeated = QList<SimpleDoubleMessage>;
|
||||
namespace SimpleDoubleMessage_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleDoubleMessage_QtProtobufNested
|
||||
|
||||
class SimpleBytesMessage;
|
||||
using SimpleBytesMessageRepeated = QList<SimpleBytesMessage>;
|
||||
namespace SimpleBytesMessage_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleBytesMessage_QtProtobufNested
|
||||
|
||||
class SimpleFixedInt32Message;
|
||||
using SimpleFixedInt32MessageRepeated = QList<SimpleFixedInt32Message>;
|
||||
namespace SimpleFixedInt32Message_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleFixedInt32Message_QtProtobufNested
|
||||
|
||||
class SimpleFixedInt64Message;
|
||||
using SimpleFixedInt64MessageRepeated = QList<SimpleFixedInt64Message>;
|
||||
namespace SimpleFixedInt64Message_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleFixedInt64Message_QtProtobufNested
|
||||
|
||||
class SimpleSFixedInt32Message;
|
||||
using SimpleSFixedInt32MessageRepeated = QList<SimpleSFixedInt32Message>;
|
||||
namespace SimpleSFixedInt32Message_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleSFixedInt32Message_QtProtobufNested
|
||||
|
||||
class SimpleSFixedInt64Message;
|
||||
using SimpleSFixedInt64MessageRepeated = QList<SimpleSFixedInt64Message>;
|
||||
namespace SimpleSFixedInt64Message_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleSFixedInt64Message_QtProtobufNested
|
||||
|
||||
class ComplexMessage;
|
||||
using ComplexMessageRepeated = QList<ComplexMessage>;
|
||||
namespace ComplexMessage_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace ComplexMessage_QtProtobufNested
|
||||
|
||||
|
||||
class EmptyMessage_QtProtobufData;
|
||||
class QPB_CUSTOM_EXPORT_NAME_EXPORT EmptyMessage : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = EmptyMessage_QtProtobufNested::QtProtobufFieldEnum;
|
||||
EmptyMessage();
|
||||
~EmptyMessage();
|
||||
EmptyMessage(const EmptyMessage &other);
|
||||
EmptyMessage &operator =(const EmptyMessage &other);
|
||||
EmptyMessage(EmptyMessage &&other) noexcept;
|
||||
EmptyMessage &operator =(EmptyMessage &&other) noexcept;
|
||||
bool operator ==(const EmptyMessage &other) const;
|
||||
bool operator !=(const EmptyMessage &other) const;
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<EmptyMessage_QtProtobufData> dptr;
|
||||
};
|
||||
namespace EmptyMessage_QtProtobufNested {
|
||||
Q_NAMESPACE_EXPORT(QPB_CUSTOM_EXPORT_NAME_EXPORT)
|
||||
|
||||
} // namespace EmptyMessage_QtProtobufNested
|
||||
|
||||
class SimpleBoolMessage_QtProtobufData;
|
||||
class QPB_CUSTOM_EXPORT_NAME_EXPORT SimpleBoolMessage : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(bool testFieldBool READ testFieldBool WRITE setTestFieldBool SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleBoolMessage_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleBoolMessage();
|
||||
~SimpleBoolMessage();
|
||||
SimpleBoolMessage(const SimpleBoolMessage &other);
|
||||
SimpleBoolMessage &operator =(const SimpleBoolMessage &other);
|
||||
SimpleBoolMessage(SimpleBoolMessage &&other) noexcept;
|
||||
SimpleBoolMessage &operator =(SimpleBoolMessage &&other) noexcept;
|
||||
bool operator ==(const SimpleBoolMessage &other) const;
|
||||
bool operator !=(const SimpleBoolMessage &other) const;
|
||||
|
||||
bool testFieldBool() const;
|
||||
void setTestFieldBool(const bool &testFieldBool);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleBoolMessage_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleBoolMessage_QtProtobufNested {
|
||||
Q_NAMESPACE_EXPORT(QPB_CUSTOM_EXPORT_NAME_EXPORT)
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldBoolProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleBoolMessage_QtProtobufNested
|
||||
|
||||
class SimpleIntMessage_QtProtobufData;
|
||||
class QPB_CUSTOM_EXPORT_NAME_EXPORT SimpleIntMessage : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::int32 testFieldInt READ testFieldInt WRITE setTestFieldInt SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleIntMessage_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleIntMessage();
|
||||
~SimpleIntMessage();
|
||||
SimpleIntMessage(const SimpleIntMessage &other);
|
||||
SimpleIntMessage &operator =(const SimpleIntMessage &other);
|
||||
SimpleIntMessage(SimpleIntMessage &&other) noexcept;
|
||||
SimpleIntMessage &operator =(SimpleIntMessage &&other) noexcept;
|
||||
bool operator ==(const SimpleIntMessage &other) const;
|
||||
bool operator !=(const SimpleIntMessage &other) const;
|
||||
|
||||
QtProtobuf::int32 testFieldInt() const;
|
||||
void setTestFieldInt(const QtProtobuf::int32 &testFieldInt);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleIntMessage_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleIntMessage_QtProtobufNested {
|
||||
Q_NAMESPACE_EXPORT(QPB_CUSTOM_EXPORT_NAME_EXPORT)
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldIntProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleIntMessage_QtProtobufNested
|
||||
|
||||
class SimpleSIntMessage_QtProtobufData;
|
||||
class QPB_CUSTOM_EXPORT_NAME_EXPORT SimpleSIntMessage : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::sint32 testFieldInt READ testFieldInt WRITE setTestFieldInt SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleSIntMessage_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleSIntMessage();
|
||||
~SimpleSIntMessage();
|
||||
SimpleSIntMessage(const SimpleSIntMessage &other);
|
||||
SimpleSIntMessage &operator =(const SimpleSIntMessage &other);
|
||||
SimpleSIntMessage(SimpleSIntMessage &&other) noexcept;
|
||||
SimpleSIntMessage &operator =(SimpleSIntMessage &&other) noexcept;
|
||||
bool operator ==(const SimpleSIntMessage &other) const;
|
||||
bool operator !=(const SimpleSIntMessage &other) const;
|
||||
|
||||
QtProtobuf::sint32 testFieldInt() const;
|
||||
void setTestFieldInt(const QtProtobuf::sint32 &testFieldInt);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleSIntMessage_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleSIntMessage_QtProtobufNested {
|
||||
Q_NAMESPACE_EXPORT(QPB_CUSTOM_EXPORT_NAME_EXPORT)
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldIntProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleSIntMessage_QtProtobufNested
|
||||
|
||||
class SimpleUIntMessage_QtProtobufData;
|
||||
class QPB_CUSTOM_EXPORT_NAME_EXPORT SimpleUIntMessage : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::uint32 testFieldInt READ testFieldInt WRITE setTestFieldInt SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleUIntMessage_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleUIntMessage();
|
||||
~SimpleUIntMessage();
|
||||
SimpleUIntMessage(const SimpleUIntMessage &other);
|
||||
SimpleUIntMessage &operator =(const SimpleUIntMessage &other);
|
||||
SimpleUIntMessage(SimpleUIntMessage &&other) noexcept;
|
||||
SimpleUIntMessage &operator =(SimpleUIntMessage &&other) noexcept;
|
||||
bool operator ==(const SimpleUIntMessage &other) const;
|
||||
bool operator !=(const SimpleUIntMessage &other) const;
|
||||
|
||||
QtProtobuf::uint32 testFieldInt() const;
|
||||
void setTestFieldInt(const QtProtobuf::uint32 &testFieldInt);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleUIntMessage_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleUIntMessage_QtProtobufNested {
|
||||
Q_NAMESPACE_EXPORT(QPB_CUSTOM_EXPORT_NAME_EXPORT)
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldIntProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleUIntMessage_QtProtobufNested
|
||||
|
||||
class SimpleInt64Message_QtProtobufData;
|
||||
class QPB_CUSTOM_EXPORT_NAME_EXPORT SimpleInt64Message : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::int64 testFieldInt READ testFieldInt WRITE setTestFieldInt SCRIPTABLE false)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleInt64Message_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleInt64Message();
|
||||
~SimpleInt64Message();
|
||||
SimpleInt64Message(const SimpleInt64Message &other);
|
||||
SimpleInt64Message &operator =(const SimpleInt64Message &other);
|
||||
SimpleInt64Message(SimpleInt64Message &&other) noexcept;
|
||||
SimpleInt64Message &operator =(SimpleInt64Message &&other) noexcept;
|
||||
bool operator ==(const SimpleInt64Message &other) const;
|
||||
bool operator !=(const SimpleInt64Message &other) const;
|
||||
|
||||
QtProtobuf::int64 testFieldInt() const;
|
||||
void setTestFieldInt(const QtProtobuf::int64 &testFieldInt);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleInt64Message_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleInt64Message_QtProtobufNested {
|
||||
Q_NAMESPACE_EXPORT(QPB_CUSTOM_EXPORT_NAME_EXPORT)
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldIntProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleInt64Message_QtProtobufNested
|
||||
|
||||
class SimpleSInt64Message_QtProtobufData;
|
||||
class QPB_CUSTOM_EXPORT_NAME_EXPORT SimpleSInt64Message : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::sint64 testFieldInt READ testFieldInt WRITE setTestFieldInt SCRIPTABLE false)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleSInt64Message_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleSInt64Message();
|
||||
~SimpleSInt64Message();
|
||||
SimpleSInt64Message(const SimpleSInt64Message &other);
|
||||
SimpleSInt64Message &operator =(const SimpleSInt64Message &other);
|
||||
SimpleSInt64Message(SimpleSInt64Message &&other) noexcept;
|
||||
SimpleSInt64Message &operator =(SimpleSInt64Message &&other) noexcept;
|
||||
bool operator ==(const SimpleSInt64Message &other) const;
|
||||
bool operator !=(const SimpleSInt64Message &other) const;
|
||||
|
||||
QtProtobuf::sint64 testFieldInt() const;
|
||||
void setTestFieldInt(const QtProtobuf::sint64 &testFieldInt);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleSInt64Message_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleSInt64Message_QtProtobufNested {
|
||||
Q_NAMESPACE_EXPORT(QPB_CUSTOM_EXPORT_NAME_EXPORT)
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldIntProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleSInt64Message_QtProtobufNested
|
||||
|
||||
class SimpleUInt64Message_QtProtobufData;
|
||||
class QPB_CUSTOM_EXPORT_NAME_EXPORT SimpleUInt64Message : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::uint64 testFieldInt READ testFieldInt WRITE setTestFieldInt SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleUInt64Message_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleUInt64Message();
|
||||
~SimpleUInt64Message();
|
||||
SimpleUInt64Message(const SimpleUInt64Message &other);
|
||||
SimpleUInt64Message &operator =(const SimpleUInt64Message &other);
|
||||
SimpleUInt64Message(SimpleUInt64Message &&other) noexcept;
|
||||
SimpleUInt64Message &operator =(SimpleUInt64Message &&other) noexcept;
|
||||
bool operator ==(const SimpleUInt64Message &other) const;
|
||||
bool operator !=(const SimpleUInt64Message &other) const;
|
||||
|
||||
QtProtobuf::uint64 testFieldInt() const;
|
||||
void setTestFieldInt(const QtProtobuf::uint64 &testFieldInt);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleUInt64Message_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleUInt64Message_QtProtobufNested {
|
||||
Q_NAMESPACE_EXPORT(QPB_CUSTOM_EXPORT_NAME_EXPORT)
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldIntProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleUInt64Message_QtProtobufNested
|
||||
|
||||
class SimpleStringMessage_QtProtobufData;
|
||||
class QPB_CUSTOM_EXPORT_NAME_EXPORT SimpleStringMessage : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QString testFieldString READ testFieldString WRITE setTestFieldString SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleStringMessage_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleStringMessage();
|
||||
~SimpleStringMessage();
|
||||
SimpleStringMessage(const SimpleStringMessage &other);
|
||||
SimpleStringMessage &operator =(const SimpleStringMessage &other);
|
||||
SimpleStringMessage(SimpleStringMessage &&other) noexcept;
|
||||
SimpleStringMessage &operator =(SimpleStringMessage &&other) noexcept;
|
||||
bool operator ==(const SimpleStringMessage &other) const;
|
||||
bool operator !=(const SimpleStringMessage &other) const;
|
||||
|
||||
QString testFieldString() const;
|
||||
void setTestFieldString(const QString &testFieldString);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleStringMessage_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleStringMessage_QtProtobufNested {
|
||||
Q_NAMESPACE_EXPORT(QPB_CUSTOM_EXPORT_NAME_EXPORT)
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldStringProtoFieldNumber = 6,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleStringMessage_QtProtobufNested
|
||||
|
||||
class SimpleFloatMessage_QtProtobufData;
|
||||
class QPB_CUSTOM_EXPORT_NAME_EXPORT SimpleFloatMessage : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(float testFieldFloat READ testFieldFloat WRITE setTestFieldFloat SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleFloatMessage_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleFloatMessage();
|
||||
~SimpleFloatMessage();
|
||||
SimpleFloatMessage(const SimpleFloatMessage &other);
|
||||
SimpleFloatMessage &operator =(const SimpleFloatMessage &other);
|
||||
SimpleFloatMessage(SimpleFloatMessage &&other) noexcept;
|
||||
SimpleFloatMessage &operator =(SimpleFloatMessage &&other) noexcept;
|
||||
bool operator ==(const SimpleFloatMessage &other) const;
|
||||
bool operator !=(const SimpleFloatMessage &other) const;
|
||||
|
||||
float testFieldFloat() const;
|
||||
void setTestFieldFloat(const float &testFieldFloat);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleFloatMessage_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleFloatMessage_QtProtobufNested {
|
||||
Q_NAMESPACE_EXPORT(QPB_CUSTOM_EXPORT_NAME_EXPORT)
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldFloatProtoFieldNumber = 7,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleFloatMessage_QtProtobufNested
|
||||
|
||||
class SimpleDoubleMessage_QtProtobufData;
|
||||
class QPB_CUSTOM_EXPORT_NAME_EXPORT SimpleDoubleMessage : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(double testFieldDouble READ testFieldDouble WRITE setTestFieldDouble SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleDoubleMessage_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleDoubleMessage();
|
||||
~SimpleDoubleMessage();
|
||||
SimpleDoubleMessage(const SimpleDoubleMessage &other);
|
||||
SimpleDoubleMessage &operator =(const SimpleDoubleMessage &other);
|
||||
SimpleDoubleMessage(SimpleDoubleMessage &&other) noexcept;
|
||||
SimpleDoubleMessage &operator =(SimpleDoubleMessage &&other) noexcept;
|
||||
bool operator ==(const SimpleDoubleMessage &other) const;
|
||||
bool operator !=(const SimpleDoubleMessage &other) const;
|
||||
|
||||
double testFieldDouble() const;
|
||||
void setTestFieldDouble(const double &testFieldDouble);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleDoubleMessage_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleDoubleMessage_QtProtobufNested {
|
||||
Q_NAMESPACE_EXPORT(QPB_CUSTOM_EXPORT_NAME_EXPORT)
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldDoubleProtoFieldNumber = 8,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleDoubleMessage_QtProtobufNested
|
||||
|
||||
class SimpleBytesMessage_QtProtobufData;
|
||||
class QPB_CUSTOM_EXPORT_NAME_EXPORT SimpleBytesMessage : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QByteArray testFieldBytes READ testFieldBytes WRITE setTestFieldBytes SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleBytesMessage_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleBytesMessage();
|
||||
~SimpleBytesMessage();
|
||||
SimpleBytesMessage(const SimpleBytesMessage &other);
|
||||
SimpleBytesMessage &operator =(const SimpleBytesMessage &other);
|
||||
SimpleBytesMessage(SimpleBytesMessage &&other) noexcept;
|
||||
SimpleBytesMessage &operator =(SimpleBytesMessage &&other) noexcept;
|
||||
bool operator ==(const SimpleBytesMessage &other) const;
|
||||
bool operator !=(const SimpleBytesMessage &other) const;
|
||||
|
||||
QByteArray testFieldBytes() const;
|
||||
void setTestFieldBytes(const QByteArray &testFieldBytes);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleBytesMessage_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleBytesMessage_QtProtobufNested {
|
||||
Q_NAMESPACE_EXPORT(QPB_CUSTOM_EXPORT_NAME_EXPORT)
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldBytesProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleBytesMessage_QtProtobufNested
|
||||
|
||||
class SimpleFixedInt32Message_QtProtobufData;
|
||||
class QPB_CUSTOM_EXPORT_NAME_EXPORT SimpleFixedInt32Message : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::fixed32 testFieldFixedInt32 READ testFieldFixedInt32 WRITE setTestFieldFixedInt32 SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleFixedInt32Message_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleFixedInt32Message();
|
||||
~SimpleFixedInt32Message();
|
||||
SimpleFixedInt32Message(const SimpleFixedInt32Message &other);
|
||||
SimpleFixedInt32Message &operator =(const SimpleFixedInt32Message &other);
|
||||
SimpleFixedInt32Message(SimpleFixedInt32Message &&other) noexcept;
|
||||
SimpleFixedInt32Message &operator =(SimpleFixedInt32Message &&other) noexcept;
|
||||
bool operator ==(const SimpleFixedInt32Message &other) const;
|
||||
bool operator !=(const SimpleFixedInt32Message &other) const;
|
||||
|
||||
QtProtobuf::fixed32 testFieldFixedInt32() const;
|
||||
void setTestFieldFixedInt32(const QtProtobuf::fixed32 &testFieldFixedInt32);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleFixedInt32Message_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleFixedInt32Message_QtProtobufNested {
|
||||
Q_NAMESPACE_EXPORT(QPB_CUSTOM_EXPORT_NAME_EXPORT)
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldFixedInt32ProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleFixedInt32Message_QtProtobufNested
|
||||
|
||||
class SimpleFixedInt64Message_QtProtobufData;
|
||||
class QPB_CUSTOM_EXPORT_NAME_EXPORT SimpleFixedInt64Message : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::fixed64 testFieldFixedInt64 READ testFieldFixedInt64 WRITE setTestFieldFixedInt64 SCRIPTABLE false)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleFixedInt64Message_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleFixedInt64Message();
|
||||
~SimpleFixedInt64Message();
|
||||
SimpleFixedInt64Message(const SimpleFixedInt64Message &other);
|
||||
SimpleFixedInt64Message &operator =(const SimpleFixedInt64Message &other);
|
||||
SimpleFixedInt64Message(SimpleFixedInt64Message &&other) noexcept;
|
||||
SimpleFixedInt64Message &operator =(SimpleFixedInt64Message &&other) noexcept;
|
||||
bool operator ==(const SimpleFixedInt64Message &other) const;
|
||||
bool operator !=(const SimpleFixedInt64Message &other) const;
|
||||
|
||||
QtProtobuf::fixed64 testFieldFixedInt64() const;
|
||||
void setTestFieldFixedInt64(const QtProtobuf::fixed64 &testFieldFixedInt64);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleFixedInt64Message_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleFixedInt64Message_QtProtobufNested {
|
||||
Q_NAMESPACE_EXPORT(QPB_CUSTOM_EXPORT_NAME_EXPORT)
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldFixedInt64ProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleFixedInt64Message_QtProtobufNested
|
||||
|
||||
class SimpleSFixedInt32Message_QtProtobufData;
|
||||
class QPB_CUSTOM_EXPORT_NAME_EXPORT SimpleSFixedInt32Message : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::sfixed32 testFieldFixedInt32 READ testFieldFixedInt32 WRITE setTestFieldFixedInt32 SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleSFixedInt32Message_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleSFixedInt32Message();
|
||||
~SimpleSFixedInt32Message();
|
||||
SimpleSFixedInt32Message(const SimpleSFixedInt32Message &other);
|
||||
SimpleSFixedInt32Message &operator =(const SimpleSFixedInt32Message &other);
|
||||
SimpleSFixedInt32Message(SimpleSFixedInt32Message &&other) noexcept;
|
||||
SimpleSFixedInt32Message &operator =(SimpleSFixedInt32Message &&other) noexcept;
|
||||
bool operator ==(const SimpleSFixedInt32Message &other) const;
|
||||
bool operator !=(const SimpleSFixedInt32Message &other) const;
|
||||
|
||||
QtProtobuf::sfixed32 testFieldFixedInt32() const;
|
||||
void setTestFieldFixedInt32(const QtProtobuf::sfixed32 &testFieldFixedInt32);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleSFixedInt32Message_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleSFixedInt32Message_QtProtobufNested {
|
||||
Q_NAMESPACE_EXPORT(QPB_CUSTOM_EXPORT_NAME_EXPORT)
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldFixedInt32ProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleSFixedInt32Message_QtProtobufNested
|
||||
|
||||
class SimpleSFixedInt64Message_QtProtobufData;
|
||||
class QPB_CUSTOM_EXPORT_NAME_EXPORT SimpleSFixedInt64Message : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::sfixed64 testFieldFixedInt64 READ testFieldFixedInt64 WRITE setTestFieldFixedInt64 SCRIPTABLE false)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleSFixedInt64Message_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleSFixedInt64Message();
|
||||
~SimpleSFixedInt64Message();
|
||||
SimpleSFixedInt64Message(const SimpleSFixedInt64Message &other);
|
||||
SimpleSFixedInt64Message &operator =(const SimpleSFixedInt64Message &other);
|
||||
SimpleSFixedInt64Message(SimpleSFixedInt64Message &&other) noexcept;
|
||||
SimpleSFixedInt64Message &operator =(SimpleSFixedInt64Message &&other) noexcept;
|
||||
bool operator ==(const SimpleSFixedInt64Message &other) const;
|
||||
bool operator !=(const SimpleSFixedInt64Message &other) const;
|
||||
|
||||
QtProtobuf::sfixed64 testFieldFixedInt64() const;
|
||||
void setTestFieldFixedInt64(const QtProtobuf::sfixed64 &testFieldFixedInt64);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleSFixedInt64Message_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleSFixedInt64Message_QtProtobufNested {
|
||||
Q_NAMESPACE_EXPORT(QPB_CUSTOM_EXPORT_NAME_EXPORT)
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldFixedInt64ProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleSFixedInt64Message_QtProtobufNested
|
||||
|
||||
class ComplexMessage_QtProtobufData;
|
||||
class QPB_CUSTOM_EXPORT_NAME_EXPORT ComplexMessage : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::int32 testFieldInt READ testFieldInt WRITE setTestFieldInt SCRIPTABLE true)
|
||||
Q_PROPERTY(qtprotobufnamespace::tests::SimpleStringMessage *testComplexField_p READ testComplexField_p WRITE setTestComplexField_p SCRIPTABLE false)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = ComplexMessage_QtProtobufNested::QtProtobufFieldEnum;
|
||||
ComplexMessage();
|
||||
~ComplexMessage();
|
||||
ComplexMessage(const ComplexMessage &other);
|
||||
ComplexMessage &operator =(const ComplexMessage &other);
|
||||
ComplexMessage(ComplexMessage &&other) noexcept;
|
||||
ComplexMessage &operator =(ComplexMessage &&other) noexcept;
|
||||
bool operator ==(const ComplexMessage &other) const;
|
||||
bool operator !=(const ComplexMessage &other) const;
|
||||
|
||||
QtProtobuf::int32 testFieldInt() const;
|
||||
|
||||
bool hasTestComplexField() const;
|
||||
SimpleStringMessage &testComplexField() const;
|
||||
void clearTestComplexField();
|
||||
void setTestFieldInt(const QtProtobuf::int32 &testFieldInt);
|
||||
void setTestComplexField(const SimpleStringMessage &testComplexField);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
SimpleStringMessage *testComplexField_p() const;
|
||||
void setTestComplexField_p(SimpleStringMessage *testComplexField);
|
||||
QExplicitlySharedDataPointer<ComplexMessage_QtProtobufData> dptr;
|
||||
};
|
||||
namespace ComplexMessage_QtProtobufNested {
|
||||
Q_NAMESPACE_EXPORT(QPB_CUSTOM_EXPORT_NAME_EXPORT)
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldIntProtoFieldNumber = 1,
|
||||
TestComplexFieldProtoFieldNumber = 2,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace ComplexMessage_QtProtobufNested
|
||||
} // namespace qtprotobufnamespace::tests
|
||||
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::EmptyMessage)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleBoolMessage)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleIntMessage)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleSIntMessage)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleUIntMessage)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleInt64Message)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleSInt64Message)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleUInt64Message)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleStringMessage)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleFloatMessage)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleDoubleMessage)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleBytesMessage)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleFixedInt32Message)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleFixedInt64Message)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleSFixedInt32Message)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleSFixedInt64Message)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::ComplexMessage)
|
||||
#endif // QPROTOBUF_BASICMESSAGES_H
|
||||
|
|
@ -0,0 +1,24 @@
|
|||
#include <QtProtobuf/qprotobufregistration.h>
|
||||
#include "basicmessages.qpb.h"
|
||||
|
||||
namespace qtprotobufnamespace::tests {
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarEmptyMessage(qRegisterProtobufType<EmptyMessage>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleBoolMessage(qRegisterProtobufType<SimpleBoolMessage>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleIntMessage(qRegisterProtobufType<SimpleIntMessage>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleSIntMessage(qRegisterProtobufType<SimpleSIntMessage>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleUIntMessage(qRegisterProtobufType<SimpleUIntMessage>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleInt64Message(qRegisterProtobufType<SimpleInt64Message>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleSInt64Message(qRegisterProtobufType<SimpleSInt64Message>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleUInt64Message(qRegisterProtobufType<SimpleUInt64Message>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleStringMessage(qRegisterProtobufType<SimpleStringMessage>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleFloatMessage(qRegisterProtobufType<SimpleFloatMessage>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleDoubleMessage(qRegisterProtobufType<SimpleDoubleMessage>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleBytesMessage(qRegisterProtobufType<SimpleBytesMessage>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleFixedInt32Message(qRegisterProtobufType<SimpleFixedInt32Message>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleFixedInt64Message(qRegisterProtobufType<SimpleFixedInt64Message>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleSFixedInt32Message(qRegisterProtobufType<SimpleSFixedInt32Message>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleSFixedInt64Message(qRegisterProtobufType<SimpleSFixedInt64Message>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarComplexMessage(qRegisterProtobufType<ComplexMessage>);
|
||||
static bool RegisterBasicmessagesProtobufTypes = [](){ qRegisterProtobufTypes(); return true; }();
|
||||
} // namespace qtprotobufnamespace::tests
|
||||
|
||||
|
|
@ -0,0 +1,12 @@
|
|||
/* This file is autogenerated. DO NOT CHANGE. All changes will be lost */
|
||||
|
||||
#if defined(QT_SHARED) || !defined(QT_STATIC)
|
||||
# if defined(QT_BUILD_CUSTOM_EXPORT_NAME_LIB)
|
||||
# define QPB_CUSTOM_EXPORT_NAME_EXPORT Q_DECL_EXPORT
|
||||
# else
|
||||
# define QPB_CUSTOM_EXPORT_NAME_EXPORT Q_DECL_IMPORT
|
||||
# endif
|
||||
#else
|
||||
# define QPB_CUSTOM_EXPORT_NAME_EXPORT
|
||||
#endif
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
|
|
@ -0,0 +1,737 @@
|
|||
/* This file is autogenerated. DO NOT CHANGE. All changes will be lost */
|
||||
|
||||
#ifndef QPROTOBUF_BASICMESSAGES_H
|
||||
#define QPROTOBUF_BASICMESSAGES_H
|
||||
|
||||
#include <QtProtobuf/qprotobufmessage.h>
|
||||
#include <QtProtobuf/qprotobufobject.h>
|
||||
#include <QtProtobuf/qprotobuflazymessagepointer.h>
|
||||
|
||||
#include <QtCore/qbytearray.h>
|
||||
#include <QtCore/qstring.h>
|
||||
|
||||
#include <QtCore/qmetatype.h>
|
||||
#include <QtCore/qlist.h>
|
||||
#include <QtCore/qshareddata.h>
|
||||
|
||||
#include <memory>
|
||||
|
||||
|
||||
namespace qtprotobufnamespace::tests {
|
||||
class EmptyMessage;
|
||||
using EmptyMessageRepeated = QList<EmptyMessage>;
|
||||
namespace EmptyMessage_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace EmptyMessage_QtProtobufNested
|
||||
|
||||
class SimpleBoolMessage;
|
||||
using SimpleBoolMessageRepeated = QList<SimpleBoolMessage>;
|
||||
namespace SimpleBoolMessage_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleBoolMessage_QtProtobufNested
|
||||
|
||||
class SimpleIntMessage;
|
||||
using SimpleIntMessageRepeated = QList<SimpleIntMessage>;
|
||||
namespace SimpleIntMessage_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleIntMessage_QtProtobufNested
|
||||
|
||||
class SimpleSIntMessage;
|
||||
using SimpleSIntMessageRepeated = QList<SimpleSIntMessage>;
|
||||
namespace SimpleSIntMessage_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleSIntMessage_QtProtobufNested
|
||||
|
||||
class SimpleUIntMessage;
|
||||
using SimpleUIntMessageRepeated = QList<SimpleUIntMessage>;
|
||||
namespace SimpleUIntMessage_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleUIntMessage_QtProtobufNested
|
||||
|
||||
class SimpleInt64Message;
|
||||
using SimpleInt64MessageRepeated = QList<SimpleInt64Message>;
|
||||
namespace SimpleInt64Message_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleInt64Message_QtProtobufNested
|
||||
|
||||
class SimpleSInt64Message;
|
||||
using SimpleSInt64MessageRepeated = QList<SimpleSInt64Message>;
|
||||
namespace SimpleSInt64Message_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleSInt64Message_QtProtobufNested
|
||||
|
||||
class SimpleUInt64Message;
|
||||
using SimpleUInt64MessageRepeated = QList<SimpleUInt64Message>;
|
||||
namespace SimpleUInt64Message_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleUInt64Message_QtProtobufNested
|
||||
|
||||
class SimpleStringMessage;
|
||||
using SimpleStringMessageRepeated = QList<SimpleStringMessage>;
|
||||
namespace SimpleStringMessage_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleStringMessage_QtProtobufNested
|
||||
|
||||
class SimpleFloatMessage;
|
||||
using SimpleFloatMessageRepeated = QList<SimpleFloatMessage>;
|
||||
namespace SimpleFloatMessage_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleFloatMessage_QtProtobufNested
|
||||
|
||||
class SimpleDoubleMessage;
|
||||
using SimpleDoubleMessageRepeated = QList<SimpleDoubleMessage>;
|
||||
namespace SimpleDoubleMessage_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleDoubleMessage_QtProtobufNested
|
||||
|
||||
class SimpleBytesMessage;
|
||||
using SimpleBytesMessageRepeated = QList<SimpleBytesMessage>;
|
||||
namespace SimpleBytesMessage_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleBytesMessage_QtProtobufNested
|
||||
|
||||
class SimpleFixedInt32Message;
|
||||
using SimpleFixedInt32MessageRepeated = QList<SimpleFixedInt32Message>;
|
||||
namespace SimpleFixedInt32Message_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleFixedInt32Message_QtProtobufNested
|
||||
|
||||
class SimpleFixedInt64Message;
|
||||
using SimpleFixedInt64MessageRepeated = QList<SimpleFixedInt64Message>;
|
||||
namespace SimpleFixedInt64Message_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleFixedInt64Message_QtProtobufNested
|
||||
|
||||
class SimpleSFixedInt32Message;
|
||||
using SimpleSFixedInt32MessageRepeated = QList<SimpleSFixedInt32Message>;
|
||||
namespace SimpleSFixedInt32Message_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleSFixedInt32Message_QtProtobufNested
|
||||
|
||||
class SimpleSFixedInt64Message;
|
||||
using SimpleSFixedInt64MessageRepeated = QList<SimpleSFixedInt64Message>;
|
||||
namespace SimpleSFixedInt64Message_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace SimpleSFixedInt64Message_QtProtobufNested
|
||||
|
||||
class ComplexMessage;
|
||||
using ComplexMessageRepeated = QList<ComplexMessage>;
|
||||
namespace ComplexMessage_QtProtobufNested {
|
||||
enum class QtProtobufFieldEnum;
|
||||
} // namespace ComplexMessage_QtProtobufNested
|
||||
|
||||
|
||||
class EmptyMessage_QtProtobufData;
|
||||
class EmptyMessage : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = EmptyMessage_QtProtobufNested::QtProtobufFieldEnum;
|
||||
EmptyMessage();
|
||||
~EmptyMessage();
|
||||
EmptyMessage(const EmptyMessage &other);
|
||||
EmptyMessage &operator =(const EmptyMessage &other);
|
||||
EmptyMessage(EmptyMessage &&other) noexcept;
|
||||
EmptyMessage &operator =(EmptyMessage &&other) noexcept;
|
||||
bool operator ==(const EmptyMessage &other) const;
|
||||
bool operator !=(const EmptyMessage &other) const;
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<EmptyMessage_QtProtobufData> dptr;
|
||||
};
|
||||
namespace EmptyMessage_QtProtobufNested {
|
||||
Q_NAMESPACE
|
||||
|
||||
} // namespace EmptyMessage_QtProtobufNested
|
||||
|
||||
class SimpleBoolMessage_QtProtobufData;
|
||||
class SimpleBoolMessage : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(bool testFieldBool READ testFieldBool WRITE setTestFieldBool SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleBoolMessage_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleBoolMessage();
|
||||
~SimpleBoolMessage();
|
||||
SimpleBoolMessage(const SimpleBoolMessage &other);
|
||||
SimpleBoolMessage &operator =(const SimpleBoolMessage &other);
|
||||
SimpleBoolMessage(SimpleBoolMessage &&other) noexcept;
|
||||
SimpleBoolMessage &operator =(SimpleBoolMessage &&other) noexcept;
|
||||
bool operator ==(const SimpleBoolMessage &other) const;
|
||||
bool operator !=(const SimpleBoolMessage &other) const;
|
||||
|
||||
bool testFieldBool() const;
|
||||
void setTestFieldBool(const bool &testFieldBool);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleBoolMessage_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleBoolMessage_QtProtobufNested {
|
||||
Q_NAMESPACE
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldBoolProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleBoolMessage_QtProtobufNested
|
||||
|
||||
class SimpleIntMessage_QtProtobufData;
|
||||
class SimpleIntMessage : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::int32 testFieldInt READ testFieldInt WRITE setTestFieldInt SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleIntMessage_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleIntMessage();
|
||||
~SimpleIntMessage();
|
||||
SimpleIntMessage(const SimpleIntMessage &other);
|
||||
SimpleIntMessage &operator =(const SimpleIntMessage &other);
|
||||
SimpleIntMessage(SimpleIntMessage &&other) noexcept;
|
||||
SimpleIntMessage &operator =(SimpleIntMessage &&other) noexcept;
|
||||
bool operator ==(const SimpleIntMessage &other) const;
|
||||
bool operator !=(const SimpleIntMessage &other) const;
|
||||
|
||||
QtProtobuf::int32 testFieldInt() const;
|
||||
void setTestFieldInt(const QtProtobuf::int32 &testFieldInt);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleIntMessage_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleIntMessage_QtProtobufNested {
|
||||
Q_NAMESPACE
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldIntProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleIntMessage_QtProtobufNested
|
||||
|
||||
class SimpleSIntMessage_QtProtobufData;
|
||||
class SimpleSIntMessage : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::sint32 testFieldInt READ testFieldInt WRITE setTestFieldInt SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleSIntMessage_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleSIntMessage();
|
||||
~SimpleSIntMessage();
|
||||
SimpleSIntMessage(const SimpleSIntMessage &other);
|
||||
SimpleSIntMessage &operator =(const SimpleSIntMessage &other);
|
||||
SimpleSIntMessage(SimpleSIntMessage &&other) noexcept;
|
||||
SimpleSIntMessage &operator =(SimpleSIntMessage &&other) noexcept;
|
||||
bool operator ==(const SimpleSIntMessage &other) const;
|
||||
bool operator !=(const SimpleSIntMessage &other) const;
|
||||
|
||||
QtProtobuf::sint32 testFieldInt() const;
|
||||
void setTestFieldInt(const QtProtobuf::sint32 &testFieldInt);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleSIntMessage_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleSIntMessage_QtProtobufNested {
|
||||
Q_NAMESPACE
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldIntProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleSIntMessage_QtProtobufNested
|
||||
|
||||
class SimpleUIntMessage_QtProtobufData;
|
||||
class SimpleUIntMessage : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::uint32 testFieldInt READ testFieldInt WRITE setTestFieldInt SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleUIntMessage_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleUIntMessage();
|
||||
~SimpleUIntMessage();
|
||||
SimpleUIntMessage(const SimpleUIntMessage &other);
|
||||
SimpleUIntMessage &operator =(const SimpleUIntMessage &other);
|
||||
SimpleUIntMessage(SimpleUIntMessage &&other) noexcept;
|
||||
SimpleUIntMessage &operator =(SimpleUIntMessage &&other) noexcept;
|
||||
bool operator ==(const SimpleUIntMessage &other) const;
|
||||
bool operator !=(const SimpleUIntMessage &other) const;
|
||||
|
||||
QtProtobuf::uint32 testFieldInt() const;
|
||||
void setTestFieldInt(const QtProtobuf::uint32 &testFieldInt);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleUIntMessage_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleUIntMessage_QtProtobufNested {
|
||||
Q_NAMESPACE
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldIntProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleUIntMessage_QtProtobufNested
|
||||
|
||||
class SimpleInt64Message_QtProtobufData;
|
||||
class SimpleInt64Message : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::int64 testFieldInt READ testFieldInt WRITE setTestFieldInt SCRIPTABLE false)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleInt64Message_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleInt64Message();
|
||||
~SimpleInt64Message();
|
||||
SimpleInt64Message(const SimpleInt64Message &other);
|
||||
SimpleInt64Message &operator =(const SimpleInt64Message &other);
|
||||
SimpleInt64Message(SimpleInt64Message &&other) noexcept;
|
||||
SimpleInt64Message &operator =(SimpleInt64Message &&other) noexcept;
|
||||
bool operator ==(const SimpleInt64Message &other) const;
|
||||
bool operator !=(const SimpleInt64Message &other) const;
|
||||
|
||||
QtProtobuf::int64 testFieldInt() const;
|
||||
void setTestFieldInt(const QtProtobuf::int64 &testFieldInt);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleInt64Message_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleInt64Message_QtProtobufNested {
|
||||
Q_NAMESPACE
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldIntProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleInt64Message_QtProtobufNested
|
||||
|
||||
class SimpleSInt64Message_QtProtobufData;
|
||||
class SimpleSInt64Message : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::sint64 testFieldInt READ testFieldInt WRITE setTestFieldInt SCRIPTABLE false)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleSInt64Message_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleSInt64Message();
|
||||
~SimpleSInt64Message();
|
||||
SimpleSInt64Message(const SimpleSInt64Message &other);
|
||||
SimpleSInt64Message &operator =(const SimpleSInt64Message &other);
|
||||
SimpleSInt64Message(SimpleSInt64Message &&other) noexcept;
|
||||
SimpleSInt64Message &operator =(SimpleSInt64Message &&other) noexcept;
|
||||
bool operator ==(const SimpleSInt64Message &other) const;
|
||||
bool operator !=(const SimpleSInt64Message &other) const;
|
||||
|
||||
QtProtobuf::sint64 testFieldInt() const;
|
||||
void setTestFieldInt(const QtProtobuf::sint64 &testFieldInt);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleSInt64Message_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleSInt64Message_QtProtobufNested {
|
||||
Q_NAMESPACE
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldIntProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleSInt64Message_QtProtobufNested
|
||||
|
||||
class SimpleUInt64Message_QtProtobufData;
|
||||
class SimpleUInt64Message : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::uint64 testFieldInt READ testFieldInt WRITE setTestFieldInt SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleUInt64Message_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleUInt64Message();
|
||||
~SimpleUInt64Message();
|
||||
SimpleUInt64Message(const SimpleUInt64Message &other);
|
||||
SimpleUInt64Message &operator =(const SimpleUInt64Message &other);
|
||||
SimpleUInt64Message(SimpleUInt64Message &&other) noexcept;
|
||||
SimpleUInt64Message &operator =(SimpleUInt64Message &&other) noexcept;
|
||||
bool operator ==(const SimpleUInt64Message &other) const;
|
||||
bool operator !=(const SimpleUInt64Message &other) const;
|
||||
|
||||
QtProtobuf::uint64 testFieldInt() const;
|
||||
void setTestFieldInt(const QtProtobuf::uint64 &testFieldInt);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleUInt64Message_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleUInt64Message_QtProtobufNested {
|
||||
Q_NAMESPACE
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldIntProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleUInt64Message_QtProtobufNested
|
||||
|
||||
class SimpleStringMessage_QtProtobufData;
|
||||
class SimpleStringMessage : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QString testFieldString READ testFieldString WRITE setTestFieldString SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleStringMessage_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleStringMessage();
|
||||
~SimpleStringMessage();
|
||||
SimpleStringMessage(const SimpleStringMessage &other);
|
||||
SimpleStringMessage &operator =(const SimpleStringMessage &other);
|
||||
SimpleStringMessage(SimpleStringMessage &&other) noexcept;
|
||||
SimpleStringMessage &operator =(SimpleStringMessage &&other) noexcept;
|
||||
bool operator ==(const SimpleStringMessage &other) const;
|
||||
bool operator !=(const SimpleStringMessage &other) const;
|
||||
|
||||
QString testFieldString() const;
|
||||
void setTestFieldString(const QString &testFieldString);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleStringMessage_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleStringMessage_QtProtobufNested {
|
||||
Q_NAMESPACE
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldStringProtoFieldNumber = 6,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleStringMessage_QtProtobufNested
|
||||
|
||||
class SimpleFloatMessage_QtProtobufData;
|
||||
class SimpleFloatMessage : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(float testFieldFloat READ testFieldFloat WRITE setTestFieldFloat SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleFloatMessage_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleFloatMessage();
|
||||
~SimpleFloatMessage();
|
||||
SimpleFloatMessage(const SimpleFloatMessage &other);
|
||||
SimpleFloatMessage &operator =(const SimpleFloatMessage &other);
|
||||
SimpleFloatMessage(SimpleFloatMessage &&other) noexcept;
|
||||
SimpleFloatMessage &operator =(SimpleFloatMessage &&other) noexcept;
|
||||
bool operator ==(const SimpleFloatMessage &other) const;
|
||||
bool operator !=(const SimpleFloatMessage &other) const;
|
||||
|
||||
float testFieldFloat() const;
|
||||
void setTestFieldFloat(const float &testFieldFloat);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleFloatMessage_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleFloatMessage_QtProtobufNested {
|
||||
Q_NAMESPACE
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldFloatProtoFieldNumber = 7,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleFloatMessage_QtProtobufNested
|
||||
|
||||
class SimpleDoubleMessage_QtProtobufData;
|
||||
class SimpleDoubleMessage : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(double testFieldDouble READ testFieldDouble WRITE setTestFieldDouble SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleDoubleMessage_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleDoubleMessage();
|
||||
~SimpleDoubleMessage();
|
||||
SimpleDoubleMessage(const SimpleDoubleMessage &other);
|
||||
SimpleDoubleMessage &operator =(const SimpleDoubleMessage &other);
|
||||
SimpleDoubleMessage(SimpleDoubleMessage &&other) noexcept;
|
||||
SimpleDoubleMessage &operator =(SimpleDoubleMessage &&other) noexcept;
|
||||
bool operator ==(const SimpleDoubleMessage &other) const;
|
||||
bool operator !=(const SimpleDoubleMessage &other) const;
|
||||
|
||||
double testFieldDouble() const;
|
||||
void setTestFieldDouble(const double &testFieldDouble);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleDoubleMessage_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleDoubleMessage_QtProtobufNested {
|
||||
Q_NAMESPACE
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldDoubleProtoFieldNumber = 8,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleDoubleMessage_QtProtobufNested
|
||||
|
||||
class SimpleBytesMessage_QtProtobufData;
|
||||
class SimpleBytesMessage : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QByteArray testFieldBytes READ testFieldBytes WRITE setTestFieldBytes SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleBytesMessage_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleBytesMessage();
|
||||
~SimpleBytesMessage();
|
||||
SimpleBytesMessage(const SimpleBytesMessage &other);
|
||||
SimpleBytesMessage &operator =(const SimpleBytesMessage &other);
|
||||
SimpleBytesMessage(SimpleBytesMessage &&other) noexcept;
|
||||
SimpleBytesMessage &operator =(SimpleBytesMessage &&other) noexcept;
|
||||
bool operator ==(const SimpleBytesMessage &other) const;
|
||||
bool operator !=(const SimpleBytesMessage &other) const;
|
||||
|
||||
QByteArray testFieldBytes() const;
|
||||
void setTestFieldBytes(const QByteArray &testFieldBytes);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleBytesMessage_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleBytesMessage_QtProtobufNested {
|
||||
Q_NAMESPACE
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldBytesProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleBytesMessage_QtProtobufNested
|
||||
|
||||
class SimpleFixedInt32Message_QtProtobufData;
|
||||
class SimpleFixedInt32Message : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::fixed32 testFieldFixedInt32 READ testFieldFixedInt32 WRITE setTestFieldFixedInt32 SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleFixedInt32Message_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleFixedInt32Message();
|
||||
~SimpleFixedInt32Message();
|
||||
SimpleFixedInt32Message(const SimpleFixedInt32Message &other);
|
||||
SimpleFixedInt32Message &operator =(const SimpleFixedInt32Message &other);
|
||||
SimpleFixedInt32Message(SimpleFixedInt32Message &&other) noexcept;
|
||||
SimpleFixedInt32Message &operator =(SimpleFixedInt32Message &&other) noexcept;
|
||||
bool operator ==(const SimpleFixedInt32Message &other) const;
|
||||
bool operator !=(const SimpleFixedInt32Message &other) const;
|
||||
|
||||
QtProtobuf::fixed32 testFieldFixedInt32() const;
|
||||
void setTestFieldFixedInt32(const QtProtobuf::fixed32 &testFieldFixedInt32);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleFixedInt32Message_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleFixedInt32Message_QtProtobufNested {
|
||||
Q_NAMESPACE
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldFixedInt32ProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleFixedInt32Message_QtProtobufNested
|
||||
|
||||
class SimpleFixedInt64Message_QtProtobufData;
|
||||
class SimpleFixedInt64Message : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::fixed64 testFieldFixedInt64 READ testFieldFixedInt64 WRITE setTestFieldFixedInt64 SCRIPTABLE false)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleFixedInt64Message_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleFixedInt64Message();
|
||||
~SimpleFixedInt64Message();
|
||||
SimpleFixedInt64Message(const SimpleFixedInt64Message &other);
|
||||
SimpleFixedInt64Message &operator =(const SimpleFixedInt64Message &other);
|
||||
SimpleFixedInt64Message(SimpleFixedInt64Message &&other) noexcept;
|
||||
SimpleFixedInt64Message &operator =(SimpleFixedInt64Message &&other) noexcept;
|
||||
bool operator ==(const SimpleFixedInt64Message &other) const;
|
||||
bool operator !=(const SimpleFixedInt64Message &other) const;
|
||||
|
||||
QtProtobuf::fixed64 testFieldFixedInt64() const;
|
||||
void setTestFieldFixedInt64(const QtProtobuf::fixed64 &testFieldFixedInt64);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleFixedInt64Message_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleFixedInt64Message_QtProtobufNested {
|
||||
Q_NAMESPACE
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldFixedInt64ProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleFixedInt64Message_QtProtobufNested
|
||||
|
||||
class SimpleSFixedInt32Message_QtProtobufData;
|
||||
class SimpleSFixedInt32Message : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::sfixed32 testFieldFixedInt32 READ testFieldFixedInt32 WRITE setTestFieldFixedInt32 SCRIPTABLE true)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleSFixedInt32Message_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleSFixedInt32Message();
|
||||
~SimpleSFixedInt32Message();
|
||||
SimpleSFixedInt32Message(const SimpleSFixedInt32Message &other);
|
||||
SimpleSFixedInt32Message &operator =(const SimpleSFixedInt32Message &other);
|
||||
SimpleSFixedInt32Message(SimpleSFixedInt32Message &&other) noexcept;
|
||||
SimpleSFixedInt32Message &operator =(SimpleSFixedInt32Message &&other) noexcept;
|
||||
bool operator ==(const SimpleSFixedInt32Message &other) const;
|
||||
bool operator !=(const SimpleSFixedInt32Message &other) const;
|
||||
|
||||
QtProtobuf::sfixed32 testFieldFixedInt32() const;
|
||||
void setTestFieldFixedInt32(const QtProtobuf::sfixed32 &testFieldFixedInt32);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleSFixedInt32Message_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleSFixedInt32Message_QtProtobufNested {
|
||||
Q_NAMESPACE
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldFixedInt32ProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleSFixedInt32Message_QtProtobufNested
|
||||
|
||||
class SimpleSFixedInt64Message_QtProtobufData;
|
||||
class SimpleSFixedInt64Message : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::sfixed64 testFieldFixedInt64 READ testFieldFixedInt64 WRITE setTestFieldFixedInt64 SCRIPTABLE false)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = SimpleSFixedInt64Message_QtProtobufNested::QtProtobufFieldEnum;
|
||||
SimpleSFixedInt64Message();
|
||||
~SimpleSFixedInt64Message();
|
||||
SimpleSFixedInt64Message(const SimpleSFixedInt64Message &other);
|
||||
SimpleSFixedInt64Message &operator =(const SimpleSFixedInt64Message &other);
|
||||
SimpleSFixedInt64Message(SimpleSFixedInt64Message &&other) noexcept;
|
||||
SimpleSFixedInt64Message &operator =(SimpleSFixedInt64Message &&other) noexcept;
|
||||
bool operator ==(const SimpleSFixedInt64Message &other) const;
|
||||
bool operator !=(const SimpleSFixedInt64Message &other) const;
|
||||
|
||||
QtProtobuf::sfixed64 testFieldFixedInt64() const;
|
||||
void setTestFieldFixedInt64(const QtProtobuf::sfixed64 &testFieldFixedInt64);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
QExplicitlySharedDataPointer<SimpleSFixedInt64Message_QtProtobufData> dptr;
|
||||
};
|
||||
namespace SimpleSFixedInt64Message_QtProtobufNested {
|
||||
Q_NAMESPACE
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldFixedInt64ProtoFieldNumber = 1,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace SimpleSFixedInt64Message_QtProtobufNested
|
||||
|
||||
class ComplexMessage_QtProtobufData;
|
||||
class ComplexMessage : public QProtobufMessage
|
||||
{
|
||||
Q_GADGET
|
||||
Q_PROTOBUF_OBJECT
|
||||
Q_PROPERTY(QtProtobuf::int32 testFieldInt READ testFieldInt WRITE setTestFieldInt SCRIPTABLE true)
|
||||
Q_PROPERTY(qtprotobufnamespace::tests::SimpleStringMessage *testComplexField_p READ testComplexField_p WRITE setTestComplexField_p SCRIPTABLE false)
|
||||
|
||||
public:
|
||||
using QtProtobufFieldEnum = ComplexMessage_QtProtobufNested::QtProtobufFieldEnum;
|
||||
ComplexMessage();
|
||||
~ComplexMessage();
|
||||
ComplexMessage(const ComplexMessage &other);
|
||||
ComplexMessage &operator =(const ComplexMessage &other);
|
||||
ComplexMessage(ComplexMessage &&other) noexcept;
|
||||
ComplexMessage &operator =(ComplexMessage &&other) noexcept;
|
||||
bool operator ==(const ComplexMessage &other) const;
|
||||
bool operator !=(const ComplexMessage &other) const;
|
||||
|
||||
QtProtobuf::int32 testFieldInt() const;
|
||||
|
||||
bool hasTestComplexField() const;
|
||||
SimpleStringMessage &testComplexField() const;
|
||||
void clearTestComplexField();
|
||||
void setTestFieldInt(const QtProtobuf::int32 &testFieldInt);
|
||||
void setTestComplexField(const SimpleStringMessage &testComplexField);
|
||||
static void registerTypes();
|
||||
|
||||
private:
|
||||
SimpleStringMessage *testComplexField_p() const;
|
||||
void setTestComplexField_p(SimpleStringMessage *testComplexField);
|
||||
QExplicitlySharedDataPointer<ComplexMessage_QtProtobufData> dptr;
|
||||
};
|
||||
namespace ComplexMessage_QtProtobufNested {
|
||||
Q_NAMESPACE
|
||||
|
||||
enum class QtProtobufFieldEnum {
|
||||
TestFieldIntProtoFieldNumber = 1,
|
||||
TestComplexFieldProtoFieldNumber = 2,
|
||||
};
|
||||
Q_ENUM_NS(QtProtobufFieldEnum)
|
||||
|
||||
} // namespace ComplexMessage_QtProtobufNested
|
||||
} // namespace qtprotobufnamespace::tests
|
||||
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::EmptyMessage)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleBoolMessage)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleIntMessage)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleSIntMessage)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleUIntMessage)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleInt64Message)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleSInt64Message)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleUInt64Message)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleStringMessage)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleFloatMessage)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleDoubleMessage)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleBytesMessage)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleFixedInt32Message)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleFixedInt64Message)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleSFixedInt32Message)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::SimpleSFixedInt64Message)
|
||||
Q_DECLARE_METATYPE(qtprotobufnamespace::tests::ComplexMessage)
|
||||
#endif // QPROTOBUF_BASICMESSAGES_H
|
||||
|
|
@ -0,0 +1,24 @@
|
|||
#include <QtProtobuf/qprotobufregistration.h>
|
||||
#include "basicmessages.qpb.h"
|
||||
|
||||
namespace qtprotobufnamespace::tests {
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarEmptyMessage(qRegisterProtobufType<EmptyMessage>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleBoolMessage(qRegisterProtobufType<SimpleBoolMessage>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleIntMessage(qRegisterProtobufType<SimpleIntMessage>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleSIntMessage(qRegisterProtobufType<SimpleSIntMessage>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleUIntMessage(qRegisterProtobufType<SimpleUIntMessage>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleInt64Message(qRegisterProtobufType<SimpleInt64Message>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleSInt64Message(qRegisterProtobufType<SimpleSInt64Message>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleUInt64Message(qRegisterProtobufType<SimpleUInt64Message>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleStringMessage(qRegisterProtobufType<SimpleStringMessage>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleFloatMessage(qRegisterProtobufType<SimpleFloatMessage>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleDoubleMessage(qRegisterProtobufType<SimpleDoubleMessage>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleBytesMessage(qRegisterProtobufType<SimpleBytesMessage>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleFixedInt32Message(qRegisterProtobufType<SimpleFixedInt32Message>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleFixedInt64Message(qRegisterProtobufType<SimpleFixedInt64Message>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleSFixedInt32Message(qRegisterProtobufType<SimpleSFixedInt32Message>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarSimpleSFixedInt64Message(qRegisterProtobufType<SimpleSFixedInt64Message>);
|
||||
static QtProtobuf::ProtoTypeRegistrar ProtoTypeRegistrarComplexMessage(qRegisterProtobufType<ComplexMessage>);
|
||||
static bool RegisterBasicmessagesProtobufTypes = [](){ qRegisterProtobufTypes(); return true; }();
|
||||
} // namespace qtprotobufnamespace::tests
|
||||
|
||||
|
|
@ -245,6 +245,16 @@ void tst_qtprotobufgen::cmakeGeneratedFile_data()
|
|||
<< "extranamespace"
|
||||
<< "/extra-namespace/"
|
||||
<< QString(extension);
|
||||
|
||||
QTest::addRow("custom-exports/basicmessages%s", extension.data())
|
||||
<< "basicmessages"
|
||||
<< "/custom-exports/"
|
||||
<< QString(extension);
|
||||
|
||||
QTest::addRow("no-exports/basicmessages%s", extension.data())
|
||||
<< "basicmessages"
|
||||
<< "/no-exports/"
|
||||
<< QString(extension);
|
||||
#ifdef HAVE_QML
|
||||
QTest::addRow("nopackage%s", extension.data())
|
||||
<< "nopackage"
|
||||
|
|
@ -252,6 +262,19 @@ void tst_qtprotobufgen::cmakeGeneratedFile_data()
|
|||
<< QString(extension);
|
||||
#endif
|
||||
}
|
||||
|
||||
//Check the generating of cpp export files
|
||||
QTest::addRow("cpp-exports")
|
||||
<< "tst_qtprotobufgen_gen_exports.qpb.h"
|
||||
<< "/folder/"
|
||||
<< QString();
|
||||
|
||||
QTest::addRow("custom-cpp-exports")
|
||||
<< "tst_qtprotobufgen_custom_exports_gen_exports.qpb.h"
|
||||
<< "/custom-exports/"
|
||||
<< QString();
|
||||
|
||||
|
||||
#ifdef HAVE_QML
|
||||
const QLatin1StringView qmlExtensions[]
|
||||
= {cppExtension,
|
||||
|
|
|
|||
Loading…
Reference in New Issue