352 lines
12 KiB
C++
Raw Normal View History

2024-11-29 17:47:45 +08:00
/****************************************************************************
** Meta object code from reading C++ file 'TcpSocket.h'
**
** Created by: The Qt Meta Object Compiler version 67 (Qt 5.13.0)
**
** WARNING! All changes made in this file will be lost!
*****************************************************************************/
#include <memory>
#include "../../../Src/TrainManager/QmlTcpSocket/TcpSocket.h"
#include <QtCore/qbytearray.h>
#include <QtCore/qmetatype.h>
#include <QtCore/QList>
#if !defined(Q_MOC_OUTPUT_REVISION)
#error "The header file 'TcpSocket.h' doesn't include <QObject>."
#elif Q_MOC_OUTPUT_REVISION != 67
#error "This file was generated using the moc from 5.13.0. It"
#error "cannot be used with the include files from this version of Qt."
#error "(The moc has changed too much.)"
#endif
QT_BEGIN_MOC_NAMESPACE
QT_WARNING_PUSH
QT_WARNING_DISABLE_DEPRECATED
struct qt_meta_stringdata_QMLTcpSockets__TcpSocket_t {
QByteArrayData data[25];
char stringdata0[318];
};
#define QT_MOC_LITERAL(idx, ofs, len) \
Q_STATIC_BYTE_ARRAY_DATA_HEADER_INITIALIZER_WITH_OFFSET(len, \
qptrdiff(offsetof(qt_meta_stringdata_QMLTcpSockets__TcpSocket_t, stringdata0) + ofs \
- idx * sizeof(QByteArrayData)) \
)
static const qt_meta_stringdata_QMLTcpSockets__TcpSocket_t qt_meta_stringdata_QMLTcpSockets__TcpSocket = {
{
QT_MOC_LITERAL(0, 0, 24), // "QMLTcpSockets::TcpSocket"
QT_MOC_LITERAL(1, 25, 11), // "peerChanged"
QT_MOC_LITERAL(2, 37, 0), // ""
QT_MOC_LITERAL(3, 38, 11), // "portChanged"
QT_MOC_LITERAL(4, 50, 9), // "connected"
QT_MOC_LITERAL(5, 60, 12), // "disconnected"
QT_MOC_LITERAL(6, 73, 5), // "error"
QT_MOC_LITERAL(7, 79, 11), // "socketError"
QT_MOC_LITERAL(8, 91, 13), // "bytesReceived"
QT_MOC_LITERAL(9, 105, 10), // "QList<int>"
QT_MOC_LITERAL(10, 116, 5), // "bytes"
QT_MOC_LITERAL(11, 122, 19), // "setSocketDescriptor"
QT_MOC_LITERAL(12, 142, 23), // "QMLTcpSockets::QIntPtr*"
QT_MOC_LITERAL(13, 166, 16), // "socketDescriptor"
QT_MOC_LITERAL(14, 183, 15), // "setSocketOption"
QT_MOC_LITERAL(15, 199, 6), // "option"
QT_MOC_LITERAL(16, 206, 5), // "value"
QT_MOC_LITERAL(17, 212, 13), // "connectToHost"
QT_MOC_LITERAL(18, 226, 18), // "disconnectFromHost"
QT_MOC_LITERAL(19, 245, 10), // "writeBytes"
QT_MOC_LITERAL(20, 256, 7), // "publish"
QT_MOC_LITERAL(21, 264, 14), // "emitErrorAsInt"
QT_MOC_LITERAL(22, 279, 28), // "QAbstractSocket::SocketError"
QT_MOC_LITERAL(23, 308, 4), // "peer"
QT_MOC_LITERAL(24, 313, 4) // "port"
},
"QMLTcpSockets::TcpSocket\0peerChanged\0"
"\0portChanged\0connected\0disconnected\0"
"error\0socketError\0bytesReceived\0"
"QList<int>\0bytes\0setSocketDescriptor\0"
"QMLTcpSockets::QIntPtr*\0socketDescriptor\0"
"setSocketOption\0option\0value\0connectToHost\0"
"disconnectFromHost\0writeBytes\0publish\0"
"emitErrorAsInt\0QAbstractSocket::SocketError\0"
"peer\0port"
};
#undef QT_MOC_LITERAL
static const uint qt_meta_data_QMLTcpSockets__TcpSocket[] = {
// content:
8, // revision
0, // classname
0, 0, // classinfo
13, 14, // methods
2, 106, // properties
0, 0, // enums/sets
0, 0, // constructors
0, // flags
6, // signalCount
// signals: name, argc, parameters, tag, flags
1, 0, 79, 2, 0x06 /* Public */,
3, 0, 80, 2, 0x06 /* Public */,
4, 0, 81, 2, 0x06 /* Public */,
5, 0, 82, 2, 0x06 /* Public */,
6, 1, 83, 2, 0x06 /* Public */,
8, 1, 86, 2, 0x06 /* Public */,
// slots: name, argc, parameters, tag, flags
11, 1, 89, 2, 0x0a /* Public */,
14, 2, 92, 2, 0x0a /* Public */,
17, 0, 97, 2, 0x0a /* Public */,
18, 0, 98, 2, 0x0a /* Public */,
19, 1, 99, 2, 0x0a /* Public */,
20, 0, 102, 2, 0x08 /* Private */,
21, 1, 103, 2, 0x08 /* Private */,
// signals: parameters
QMetaType::Void,
QMetaType::Void,
QMetaType::Void,
QMetaType::Void,
QMetaType::Void, QMetaType::Int, 7,
QMetaType::Void, 0x80000000 | 9, 10,
// slots: parameters
QMetaType::Void, 0x80000000 | 12, 13,
QMetaType::Void, QMetaType::Int, QMetaType::QVariant, 15, 16,
QMetaType::Void,
QMetaType::Void,
QMetaType::Bool, 0x80000000 | 9, 10,
QMetaType::Void,
QMetaType::Void, 0x80000000 | 22, 7,
// properties: name, type, flags
23, QMetaType::QString, 0x00495103,
24, QMetaType::Int, 0x00495103,
// properties: notify_signal_id
0,
1,
0 // eod
};
void QMLTcpSockets::TcpSocket::qt_static_metacall(QObject *_o, QMetaObject::Call _c, int _id, void **_a)
{
if (_c == QMetaObject::InvokeMetaMethod) {
auto *_t = static_cast<TcpSocket *>(_o);
Q_UNUSED(_t)
switch (_id) {
case 0: _t->peerChanged(); break;
case 1: _t->portChanged(); break;
case 2: _t->connected(); break;
case 3: _t->disconnected(); break;
case 4: _t->error((*reinterpret_cast< int(*)>(_a[1]))); break;
case 5: _t->bytesReceived((*reinterpret_cast< QList<int>(*)>(_a[1]))); break;
case 6: _t->setSocketDescriptor((*reinterpret_cast< QMLTcpSockets::QIntPtr*(*)>(_a[1]))); break;
case 7: _t->setSocketOption((*reinterpret_cast< int(*)>(_a[1])),(*reinterpret_cast< QVariant(*)>(_a[2]))); break;
case 8: _t->connectToHost(); break;
case 9: _t->disconnectFromHost(); break;
case 10: { bool _r = _t->writeBytes((*reinterpret_cast< QList<int>(*)>(_a[1])));
if (_a[0]) *reinterpret_cast< bool*>(_a[0]) = std::move(_r); } break;
case 11: _t->publish(); break;
case 12: _t->emitErrorAsInt((*reinterpret_cast< QAbstractSocket::SocketError(*)>(_a[1]))); break;
default: ;
}
} else if (_c == QMetaObject::RegisterMethodArgumentMetaType) {
switch (_id) {
default: *reinterpret_cast<int*>(_a[0]) = -1; break;
case 5:
switch (*reinterpret_cast<int*>(_a[1])) {
default: *reinterpret_cast<int*>(_a[0]) = -1; break;
case 0:
*reinterpret_cast<int*>(_a[0]) = qRegisterMetaType< QList<int> >(); break;
}
break;
case 6:
switch (*reinterpret_cast<int*>(_a[1])) {
default: *reinterpret_cast<int*>(_a[0]) = -1; break;
case 0:
*reinterpret_cast<int*>(_a[0]) = qRegisterMetaType< QMLTcpSockets::QIntPtr* >(); break;
}
break;
case 10:
switch (*reinterpret_cast<int*>(_a[1])) {
default: *reinterpret_cast<int*>(_a[0]) = -1; break;
case 0:
*reinterpret_cast<int*>(_a[0]) = qRegisterMetaType< QList<int> >(); break;
}
break;
case 12:
switch (*reinterpret_cast<int*>(_a[1])) {
default: *reinterpret_cast<int*>(_a[0]) = -1; break;
case 0:
*reinterpret_cast<int*>(_a[0]) = qRegisterMetaType< QAbstractSocket::SocketError >(); break;
}
break;
}
} else if (_c == QMetaObject::IndexOfMethod) {
int *result = reinterpret_cast<int *>(_a[0]);
{
using _t = void (TcpSocket::*)();
if (*reinterpret_cast<_t *>(_a[1]) == static_cast<_t>(&TcpSocket::peerChanged)) {
*result = 0;
return;
}
}
{
using _t = void (TcpSocket::*)();
if (*reinterpret_cast<_t *>(_a[1]) == static_cast<_t>(&TcpSocket::portChanged)) {
*result = 1;
return;
}
}
{
using _t = void (TcpSocket::*)();
if (*reinterpret_cast<_t *>(_a[1]) == static_cast<_t>(&TcpSocket::connected)) {
*result = 2;
return;
}
}
{
using _t = void (TcpSocket::*)();
if (*reinterpret_cast<_t *>(_a[1]) == static_cast<_t>(&TcpSocket::disconnected)) {
*result = 3;
return;
}
}
{
using _t = void (TcpSocket::*)(int );
if (*reinterpret_cast<_t *>(_a[1]) == static_cast<_t>(&TcpSocket::error)) {
*result = 4;
return;
}
}
{
using _t = void (TcpSocket::*)(QList<int> );
if (*reinterpret_cast<_t *>(_a[1]) == static_cast<_t>(&TcpSocket::bytesReceived)) {
*result = 5;
return;
}
}
}
#ifndef QT_NO_PROPERTIES
else if (_c == QMetaObject::ReadProperty) {
auto *_t = static_cast<TcpSocket *>(_o);
Q_UNUSED(_t)
void *_v = _a[0];
switch (_id) {
case 0: *reinterpret_cast< QString*>(_v) = _t->getPeer(); break;
case 1: *reinterpret_cast< int*>(_v) = _t->getPort(); break;
default: break;
}
} else if (_c == QMetaObject::WriteProperty) {
auto *_t = static_cast<TcpSocket *>(_o);
Q_UNUSED(_t)
void *_v = _a[0];
switch (_id) {
case 0: _t->setPeer(*reinterpret_cast< QString*>(_v)); break;
case 1: _t->setPort(*reinterpret_cast< int*>(_v)); break;
default: break;
}
} else if (_c == QMetaObject::ResetProperty) {
}
#endif // QT_NO_PROPERTIES
}
QT_INIT_METAOBJECT const QMetaObject QMLTcpSockets::TcpSocket::staticMetaObject = { {
&QQuickItem::staticMetaObject,
qt_meta_stringdata_QMLTcpSockets__TcpSocket.data,
qt_meta_data_QMLTcpSockets__TcpSocket,
qt_static_metacall,
nullptr,
nullptr
} };
const QMetaObject *QMLTcpSockets::TcpSocket::metaObject() const
{
return QObject::d_ptr->metaObject ? QObject::d_ptr->dynamicMetaObject() : &staticMetaObject;
}
void *QMLTcpSockets::TcpSocket::qt_metacast(const char *_clname)
{
if (!_clname) return nullptr;
if (!strcmp(_clname, qt_meta_stringdata_QMLTcpSockets__TcpSocket.stringdata0))
return static_cast<void*>(this);
return QQuickItem::qt_metacast(_clname);
}
int QMLTcpSockets::TcpSocket::qt_metacall(QMetaObject::Call _c, int _id, void **_a)
{
_id = QQuickItem::qt_metacall(_c, _id, _a);
if (_id < 0)
return _id;
if (_c == QMetaObject::InvokeMetaMethod) {
if (_id < 13)
qt_static_metacall(this, _c, _id, _a);
_id -= 13;
} else if (_c == QMetaObject::RegisterMethodArgumentMetaType) {
if (_id < 13)
qt_static_metacall(this, _c, _id, _a);
_id -= 13;
}
#ifndef QT_NO_PROPERTIES
else if (_c == QMetaObject::ReadProperty || _c == QMetaObject::WriteProperty
|| _c == QMetaObject::ResetProperty || _c == QMetaObject::RegisterPropertyMetaType) {
qt_static_metacall(this, _c, _id, _a);
_id -= 2;
} else if (_c == QMetaObject::QueryPropertyDesignable) {
_id -= 2;
} else if (_c == QMetaObject::QueryPropertyScriptable) {
_id -= 2;
} else if (_c == QMetaObject::QueryPropertyStored) {
_id -= 2;
} else if (_c == QMetaObject::QueryPropertyEditable) {
_id -= 2;
} else if (_c == QMetaObject::QueryPropertyUser) {
_id -= 2;
}
#endif // QT_NO_PROPERTIES
return _id;
}
// SIGNAL 0
void QMLTcpSockets::TcpSocket::peerChanged()
{
QMetaObject::activate(this, &staticMetaObject, 0, nullptr);
}
// SIGNAL 1
void QMLTcpSockets::TcpSocket::portChanged()
{
QMetaObject::activate(this, &staticMetaObject, 1, nullptr);
}
// SIGNAL 2
void QMLTcpSockets::TcpSocket::connected()
{
QMetaObject::activate(this, &staticMetaObject, 2, nullptr);
}
// SIGNAL 3
void QMLTcpSockets::TcpSocket::disconnected()
{
QMetaObject::activate(this, &staticMetaObject, 3, nullptr);
}
// SIGNAL 4
void QMLTcpSockets::TcpSocket::error(int _t1)
{
void *_a[] = { nullptr, const_cast<void*>(reinterpret_cast<const void*>(std::addressof(_t1))) };
QMetaObject::activate(this, &staticMetaObject, 4, _a);
}
// SIGNAL 5
void QMLTcpSockets::TcpSocket::bytesReceived(QList<int> _t1)
{
void *_a[] = { nullptr, const_cast<void*>(reinterpret_cast<const void*>(std::addressof(_t1))) };
QMetaObject::activate(this, &staticMetaObject, 5, _a);
}
QT_WARNING_POP
QT_END_MOC_NAMESPACE