|
|
#include "PythonQtWrapper_QProcess.h"
|
|
|
|
|
|
#include <PythonQtSignalReceiver.h>
|
|
|
#include <PythonQtMethodInfo.h>
|
|
|
#include <PythonQtConversion.h>
|
|
|
#include <QVariant>
|
|
|
#include <qbytearray.h>
|
|
|
#include <qcoreevent.h>
|
|
|
#include <qlist.h>
|
|
|
#include <qobject.h>
|
|
|
#include <qprocess.h>
|
|
|
#include <qstringlist.h>
|
|
|
|
|
|
bool PythonQtShell_QProcess::atEnd() const
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "atEnd");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={"bool"};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(1, argumentList);
|
|
|
bool returnValue;
|
|
|
void* args[1] = {NULL};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) {
|
|
|
args[0] = PythonQtConv::ConvertPythonToQt(methodInfo->parameters().at(0), result, false, NULL, &returnValue);
|
|
|
if (args[0]!=&returnValue) {
|
|
|
if (args[0]==NULL) {
|
|
|
PythonQt::priv()->handleVirtualOverloadReturnError("atEnd", methodInfo, result);
|
|
|
} else {
|
|
|
returnValue = *((bool*)args[0]);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return returnValue;
|
|
|
}
|
|
|
}
|
|
|
return QProcess::atEnd();
|
|
|
}
|
|
|
qint64 PythonQtShell_QProcess::bytesAvailable() const
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "bytesAvailable");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={"qint64"};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(1, argumentList);
|
|
|
qint64 returnValue;
|
|
|
void* args[1] = {NULL};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) {
|
|
|
args[0] = PythonQtConv::ConvertPythonToQt(methodInfo->parameters().at(0), result, false, NULL, &returnValue);
|
|
|
if (args[0]!=&returnValue) {
|
|
|
if (args[0]==NULL) {
|
|
|
PythonQt::priv()->handleVirtualOverloadReturnError("bytesAvailable", methodInfo, result);
|
|
|
} else {
|
|
|
returnValue = *((qint64*)args[0]);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return returnValue;
|
|
|
}
|
|
|
}
|
|
|
return QProcess::bytesAvailable();
|
|
|
}
|
|
|
qint64 PythonQtShell_QProcess::bytesToWrite() const
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "bytesToWrite");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={"qint64"};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(1, argumentList);
|
|
|
qint64 returnValue;
|
|
|
void* args[1] = {NULL};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) {
|
|
|
args[0] = PythonQtConv::ConvertPythonToQt(methodInfo->parameters().at(0), result, false, NULL, &returnValue);
|
|
|
if (args[0]!=&returnValue) {
|
|
|
if (args[0]==NULL) {
|
|
|
PythonQt::priv()->handleVirtualOverloadReturnError("bytesToWrite", methodInfo, result);
|
|
|
} else {
|
|
|
returnValue = *((qint64*)args[0]);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return returnValue;
|
|
|
}
|
|
|
}
|
|
|
return QProcess::bytesToWrite();
|
|
|
}
|
|
|
bool PythonQtShell_QProcess::canReadLine() const
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "canReadLine");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={"bool"};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(1, argumentList);
|
|
|
bool returnValue;
|
|
|
void* args[1] = {NULL};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) {
|
|
|
args[0] = PythonQtConv::ConvertPythonToQt(methodInfo->parameters().at(0), result, false, NULL, &returnValue);
|
|
|
if (args[0]!=&returnValue) {
|
|
|
if (args[0]==NULL) {
|
|
|
PythonQt::priv()->handleVirtualOverloadReturnError("canReadLine", methodInfo, result);
|
|
|
} else {
|
|
|
returnValue = *((bool*)args[0]);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return returnValue;
|
|
|
}
|
|
|
}
|
|
|
return QProcess::canReadLine();
|
|
|
}
|
|
|
void PythonQtShell_QProcess::childEvent(QChildEvent* arg__1)
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "childEvent");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={"" , "QChildEvent*"};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(2, argumentList);
|
|
|
void* args[2] = {NULL, (void*)&arg__1};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return;
|
|
|
}
|
|
|
}
|
|
|
QProcess::childEvent(arg__1);
|
|
|
}
|
|
|
void PythonQtShell_QProcess::close()
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "close");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={""};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(1, argumentList);
|
|
|
void* args[1] = {NULL};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return;
|
|
|
}
|
|
|
}
|
|
|
QProcess::close();
|
|
|
}
|
|
|
void PythonQtShell_QProcess::customEvent(QEvent* arg__1)
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "customEvent");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={"" , "QEvent*"};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(2, argumentList);
|
|
|
void* args[2] = {NULL, (void*)&arg__1};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return;
|
|
|
}
|
|
|
}
|
|
|
QProcess::customEvent(arg__1);
|
|
|
}
|
|
|
bool PythonQtShell_QProcess::event(QEvent* arg__1)
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "event");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={"bool" , "QEvent*"};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(2, argumentList);
|
|
|
bool returnValue;
|
|
|
void* args[2] = {NULL, (void*)&arg__1};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) {
|
|
|
args[0] = PythonQtConv::ConvertPythonToQt(methodInfo->parameters().at(0), result, false, NULL, &returnValue);
|
|
|
if (args[0]!=&returnValue) {
|
|
|
if (args[0]==NULL) {
|
|
|
PythonQt::priv()->handleVirtualOverloadReturnError("event", methodInfo, result);
|
|
|
} else {
|
|
|
returnValue = *((bool*)args[0]);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return returnValue;
|
|
|
}
|
|
|
}
|
|
|
return QProcess::event(arg__1);
|
|
|
}
|
|
|
bool PythonQtShell_QProcess::eventFilter(QObject* arg__1, QEvent* arg__2)
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "eventFilter");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={"bool" , "QObject*" , "QEvent*"};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(3, argumentList);
|
|
|
bool returnValue;
|
|
|
void* args[3] = {NULL, (void*)&arg__1, (void*)&arg__2};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) {
|
|
|
args[0] = PythonQtConv::ConvertPythonToQt(methodInfo->parameters().at(0), result, false, NULL, &returnValue);
|
|
|
if (args[0]!=&returnValue) {
|
|
|
if (args[0]==NULL) {
|
|
|
PythonQt::priv()->handleVirtualOverloadReturnError("eventFilter", methodInfo, result);
|
|
|
} else {
|
|
|
returnValue = *((bool*)args[0]);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return returnValue;
|
|
|
}
|
|
|
}
|
|
|
return QProcess::eventFilter(arg__1, arg__2);
|
|
|
}
|
|
|
bool PythonQtShell_QProcess::isSequential() const
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "isSequential");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={"bool"};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(1, argumentList);
|
|
|
bool returnValue;
|
|
|
void* args[1] = {NULL};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) {
|
|
|
args[0] = PythonQtConv::ConvertPythonToQt(methodInfo->parameters().at(0), result, false, NULL, &returnValue);
|
|
|
if (args[0]!=&returnValue) {
|
|
|
if (args[0]==NULL) {
|
|
|
PythonQt::priv()->handleVirtualOverloadReturnError("isSequential", methodInfo, result);
|
|
|
} else {
|
|
|
returnValue = *((bool*)args[0]);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return returnValue;
|
|
|
}
|
|
|
}
|
|
|
return QProcess::isSequential();
|
|
|
}
|
|
|
bool PythonQtShell_QProcess::open(QIODevice::OpenMode mode)
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "open");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={"bool" , "QIODevice::OpenMode"};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(2, argumentList);
|
|
|
bool returnValue;
|
|
|
void* args[2] = {NULL, (void*)&mode};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) {
|
|
|
args[0] = PythonQtConv::ConvertPythonToQt(methodInfo->parameters().at(0), result, false, NULL, &returnValue);
|
|
|
if (args[0]!=&returnValue) {
|
|
|
if (args[0]==NULL) {
|
|
|
PythonQt::priv()->handleVirtualOverloadReturnError("open", methodInfo, result);
|
|
|
} else {
|
|
|
returnValue = *((bool*)args[0]);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return returnValue;
|
|
|
}
|
|
|
}
|
|
|
return QProcess::open(mode);
|
|
|
}
|
|
|
qint64 PythonQtShell_QProcess::pos() const
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "pos");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={"qint64"};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(1, argumentList);
|
|
|
qint64 returnValue;
|
|
|
void* args[1] = {NULL};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) {
|
|
|
args[0] = PythonQtConv::ConvertPythonToQt(methodInfo->parameters().at(0), result, false, NULL, &returnValue);
|
|
|
if (args[0]!=&returnValue) {
|
|
|
if (args[0]==NULL) {
|
|
|
PythonQt::priv()->handleVirtualOverloadReturnError("pos", methodInfo, result);
|
|
|
} else {
|
|
|
returnValue = *((qint64*)args[0]);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return returnValue;
|
|
|
}
|
|
|
}
|
|
|
return QProcess::pos();
|
|
|
}
|
|
|
qint64 PythonQtShell_QProcess::readData(char* data, qint64 maxlen)
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "readData");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={"qint64" , "char*" , "qint64"};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(3, argumentList);
|
|
|
qint64 returnValue;
|
|
|
void* args[3] = {NULL, (void*)&data, (void*)&maxlen};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) {
|
|
|
args[0] = PythonQtConv::ConvertPythonToQt(methodInfo->parameters().at(0), result, false, NULL, &returnValue);
|
|
|
if (args[0]!=&returnValue) {
|
|
|
if (args[0]==NULL) {
|
|
|
PythonQt::priv()->handleVirtualOverloadReturnError("readData", methodInfo, result);
|
|
|
} else {
|
|
|
returnValue = *((qint64*)args[0]);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return returnValue;
|
|
|
}
|
|
|
}
|
|
|
return QProcess::readData(data, maxlen);
|
|
|
}
|
|
|
qint64 PythonQtShell_QProcess::readLineData(char* data, qint64 maxlen)
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "readLineData");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={"qint64" , "char*" , "qint64"};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(3, argumentList);
|
|
|
qint64 returnValue;
|
|
|
void* args[3] = {NULL, (void*)&data, (void*)&maxlen};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) {
|
|
|
args[0] = PythonQtConv::ConvertPythonToQt(methodInfo->parameters().at(0), result, false, NULL, &returnValue);
|
|
|
if (args[0]!=&returnValue) {
|
|
|
if (args[0]==NULL) {
|
|
|
PythonQt::priv()->handleVirtualOverloadReturnError("readLineData", methodInfo, result);
|
|
|
} else {
|
|
|
returnValue = *((qint64*)args[0]);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return returnValue;
|
|
|
}
|
|
|
}
|
|
|
return QProcess::readLineData(data, maxlen);
|
|
|
}
|
|
|
bool PythonQtShell_QProcess::reset()
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "reset");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={"bool"};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(1, argumentList);
|
|
|
bool returnValue;
|
|
|
void* args[1] = {NULL};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) {
|
|
|
args[0] = PythonQtConv::ConvertPythonToQt(methodInfo->parameters().at(0), result, false, NULL, &returnValue);
|
|
|
if (args[0]!=&returnValue) {
|
|
|
if (args[0]==NULL) {
|
|
|
PythonQt::priv()->handleVirtualOverloadReturnError("reset", methodInfo, result);
|
|
|
} else {
|
|
|
returnValue = *((bool*)args[0]);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return returnValue;
|
|
|
}
|
|
|
}
|
|
|
return QProcess::reset();
|
|
|
}
|
|
|
bool PythonQtShell_QProcess::seek(qint64 pos)
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "seek");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={"bool" , "qint64"};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(2, argumentList);
|
|
|
bool returnValue;
|
|
|
void* args[2] = {NULL, (void*)&pos};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) {
|
|
|
args[0] = PythonQtConv::ConvertPythonToQt(methodInfo->parameters().at(0), result, false, NULL, &returnValue);
|
|
|
if (args[0]!=&returnValue) {
|
|
|
if (args[0]==NULL) {
|
|
|
PythonQt::priv()->handleVirtualOverloadReturnError("seek", methodInfo, result);
|
|
|
} else {
|
|
|
returnValue = *((bool*)args[0]);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return returnValue;
|
|
|
}
|
|
|
}
|
|
|
return QProcess::seek(pos);
|
|
|
}
|
|
|
void PythonQtShell_QProcess::setupChildProcess()
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "setupChildProcess");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={""};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(1, argumentList);
|
|
|
void* args[1] = {NULL};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return;
|
|
|
}
|
|
|
}
|
|
|
QProcess::setupChildProcess();
|
|
|
}
|
|
|
qint64 PythonQtShell_QProcess::size() const
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "size");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={"qint64"};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(1, argumentList);
|
|
|
qint64 returnValue;
|
|
|
void* args[1] = {NULL};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) {
|
|
|
args[0] = PythonQtConv::ConvertPythonToQt(methodInfo->parameters().at(0), result, false, NULL, &returnValue);
|
|
|
if (args[0]!=&returnValue) {
|
|
|
if (args[0]==NULL) {
|
|
|
PythonQt::priv()->handleVirtualOverloadReturnError("size", methodInfo, result);
|
|
|
} else {
|
|
|
returnValue = *((qint64*)args[0]);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return returnValue;
|
|
|
}
|
|
|
}
|
|
|
return QProcess::size();
|
|
|
}
|
|
|
void PythonQtShell_QProcess::timerEvent(QTimerEvent* arg__1)
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "timerEvent");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={"" , "QTimerEvent*"};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(2, argumentList);
|
|
|
void* args[2] = {NULL, (void*)&arg__1};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return;
|
|
|
}
|
|
|
}
|
|
|
QProcess::timerEvent(arg__1);
|
|
|
}
|
|
|
bool PythonQtShell_QProcess::waitForBytesWritten(int msecs)
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "waitForBytesWritten");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={"bool" , "int"};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(2, argumentList);
|
|
|
bool returnValue;
|
|
|
void* args[2] = {NULL, (void*)&msecs};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) {
|
|
|
args[0] = PythonQtConv::ConvertPythonToQt(methodInfo->parameters().at(0), result, false, NULL, &returnValue);
|
|
|
if (args[0]!=&returnValue) {
|
|
|
if (args[0]==NULL) {
|
|
|
PythonQt::priv()->handleVirtualOverloadReturnError("waitForBytesWritten", methodInfo, result);
|
|
|
} else {
|
|
|
returnValue = *((bool*)args[0]);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return returnValue;
|
|
|
}
|
|
|
}
|
|
|
return QProcess::waitForBytesWritten(msecs);
|
|
|
}
|
|
|
bool PythonQtShell_QProcess::waitForReadyRead(int msecs)
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "waitForReadyRead");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={"bool" , "int"};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(2, argumentList);
|
|
|
bool returnValue;
|
|
|
void* args[2] = {NULL, (void*)&msecs};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) {
|
|
|
args[0] = PythonQtConv::ConvertPythonToQt(methodInfo->parameters().at(0), result, false, NULL, &returnValue);
|
|
|
if (args[0]!=&returnValue) {
|
|
|
if (args[0]==NULL) {
|
|
|
PythonQt::priv()->handleVirtualOverloadReturnError("waitForReadyRead", methodInfo, result);
|
|
|
} else {
|
|
|
returnValue = *((bool*)args[0]);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return returnValue;
|
|
|
}
|
|
|
}
|
|
|
return QProcess::waitForReadyRead(msecs);
|
|
|
}
|
|
|
qint64 PythonQtShell_QProcess::writeData(const char* data, qint64 len)
|
|
|
{
|
|
|
if (_wrapper) {
|
|
|
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "writeData");
|
|
|
PyErr_Clear();
|
|
|
if (obj && !PythonQtSlotFunction_Check(obj)) {
|
|
|
static const char* argumentList[] ={"qint64" , "const char*" , "qint64"};
|
|
|
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(3, argumentList);
|
|
|
qint64 returnValue;
|
|
|
void* args[3] = {NULL, (void*)&data, (void*)&len};
|
|
|
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true);
|
|
|
if (result) {
|
|
|
args[0] = PythonQtConv::ConvertPythonToQt(methodInfo->parameters().at(0), result, false, NULL, &returnValue);
|
|
|
if (args[0]!=&returnValue) {
|
|
|
if (args[0]==NULL) {
|
|
|
PythonQt::priv()->handleVirtualOverloadReturnError("writeData", methodInfo, result);
|
|
|
} else {
|
|
|
returnValue = *((qint64*)args[0]);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
if (result) { Py_DECREF(result); }
|
|
|
Py_DECREF(obj);
|
|
|
return returnValue;
|
|
|
}
|
|
|
}
|
|
|
return QProcess::writeData(data, len);
|
|
|
}
|
|
|
QProcess* PythonQtWrapper_QProcess::new_QProcess(QObject* parent)
|
|
|
{
|
|
|
return new PythonQtShell_QProcess(parent); }
|
|
|
|
|
|
qint64 PythonQtWrapper_QProcess::bytesAvailable(QProcess* theWrappedObject) const
|
|
|
{
|
|
|
return ( ((PythonQtPublicPromoter_QProcess*)theWrappedObject)->promoted_bytesAvailable());
|
|
|
}
|
|
|
|
|
|
void PythonQtWrapper_QProcess::closeReadChannel(QProcess* theWrappedObject, QProcess::ProcessChannel channel)
|
|
|
{
|
|
|
( theWrappedObject->closeReadChannel(channel));
|
|
|
}
|
|
|
|
|
|
void PythonQtWrapper_QProcess::setStandardInputFile(QProcess* theWrappedObject, const QString& fileName)
|
|
|
{
|
|
|
( theWrappedObject->setStandardInputFile(fileName));
|
|
|
}
|
|
|
|
|
|
bool PythonQtWrapper_QProcess::isSequential(QProcess* theWrappedObject) const
|
|
|
{
|
|
|
return ( ((PythonQtPublicPromoter_QProcess*)theWrappedObject)->promoted_isSequential());
|
|
|
}
|
|
|
|
|
|
QProcess::ProcessError PythonQtWrapper_QProcess::error(QProcess* theWrappedObject) const
|
|
|
{
|
|
|
return ( theWrappedObject->error());
|
|
|
}
|
|
|
|
|
|
QProcess::ProcessChannel PythonQtWrapper_QProcess::readChannel(QProcess* theWrappedObject) const
|
|
|
{
|
|
|
return ( theWrappedObject->readChannel());
|
|
|
}
|
|
|
|
|
|
bool PythonQtWrapper_QProcess::static_QProcess_startDetached(const QString& program, const QStringList& arguments, const QString& workingDirectory, qint64* pid)
|
|
|
{
|
|
|
return (QProcess::startDetached(program, arguments, workingDirectory, pid));
|
|
|
}
|
|
|
|
|
|
bool PythonQtWrapper_QProcess::waitForFinished(QProcess* theWrappedObject, int msecs)
|
|
|
{
|
|
|
return ( theWrappedObject->waitForFinished(msecs));
|
|
|
}
|
|
|
|
|
|
QStringList PythonQtWrapper_QProcess::environment(QProcess* theWrappedObject) const
|
|
|
{
|
|
|
return ( theWrappedObject->environment());
|
|
|
}
|
|
|
|
|
|
void PythonQtWrapper_QProcess::setStandardOutputProcess(QProcess* theWrappedObject, QProcess* destination)
|
|
|
{
|
|
|
( theWrappedObject->setStandardOutputProcess(destination));
|
|
|
}
|
|
|
|
|
|
QByteArray PythonQtWrapper_QProcess::readAllStandardError(QProcess* theWrappedObject)
|
|
|
{
|
|
|
return ( theWrappedObject->readAllStandardError());
|
|
|
}
|
|
|
|
|
|
void PythonQtWrapper_QProcess::start(QProcess* theWrappedObject, const QString& program, const QStringList& arguments, QIODevice::OpenMode mode)
|
|
|
{
|
|
|
( theWrappedObject->start(program, arguments, mode));
|
|
|
}
|
|
|
|
|
|
qint64 PythonQtWrapper_QProcess::readData(QProcess* theWrappedObject, char* data, qint64 maxlen)
|
|
|
{
|
|
|
return ( ((PythonQtPublicPromoter_QProcess*)theWrappedObject)->promoted_readData(data, maxlen));
|
|
|
}
|
|
|
|
|
|
QString PythonQtWrapper_QProcess::workingDirectory(QProcess* theWrappedObject) const
|
|
|
{
|
|
|
return ( theWrappedObject->workingDirectory());
|
|
|
}
|
|
|
|
|
|
bool PythonQtWrapper_QProcess::static_QProcess_startDetached(const QString& program)
|
|
|
{
|
|
|
return (QProcess::startDetached(program));
|
|
|
}
|
|
|
|
|
|
bool PythonQtWrapper_QProcess::waitForBytesWritten(QProcess* theWrappedObject, int msecs)
|
|
|
{
|
|
|
return ( ((PythonQtPublicPromoter_QProcess*)theWrappedObject)->promoted_waitForBytesWritten(msecs));
|
|
|
}
|
|
|
|
|
|
void PythonQtWrapper_QProcess::setStandardErrorFile(QProcess* theWrappedObject, const QString& fileName, QIODevice::OpenMode mode)
|
|
|
{
|
|
|
( theWrappedObject->setStandardErrorFile(fileName, mode));
|
|
|
}
|
|
|
|
|
|
bool PythonQtWrapper_QProcess::waitForReadyRead(QProcess* theWrappedObject, int msecs)
|
|
|
{
|
|
|
return ( ((PythonQtPublicPromoter_QProcess*)theWrappedObject)->promoted_waitForReadyRead(msecs));
|
|
|
}
|
|
|
|
|
|
int PythonQtWrapper_QProcess::exitCode(QProcess* theWrappedObject) const
|
|
|
{
|
|
|
return ( theWrappedObject->exitCode());
|
|
|
}
|
|
|
|
|
|
bool PythonQtWrapper_QProcess::waitForStarted(QProcess* theWrappedObject, int msecs)
|
|
|
{
|
|
|
return ( theWrappedObject->waitForStarted(msecs));
|
|
|
}
|
|
|
|
|
|
int PythonQtWrapper_QProcess::static_QProcess_execute(const QString& program, const QStringList& arguments)
|
|
|
{
|
|
|
return (QProcess::execute(program, arguments));
|
|
|
}
|
|
|
|
|
|
bool PythonQtWrapper_QProcess::static_QProcess_startDetached(const QString& program, const QStringList& arguments)
|
|
|
{
|
|
|
return (QProcess::startDetached(program, arguments));
|
|
|
}
|
|
|
|
|
|
int PythonQtWrapper_QProcess::static_QProcess_execute(const QString& program)
|
|
|
{
|
|
|
return (QProcess::execute(program));
|
|
|
}
|
|
|
|
|
|
void PythonQtWrapper_QProcess::start(QProcess* theWrappedObject, const QString& program, QIODevice::OpenMode mode)
|
|
|
{
|
|
|
( theWrappedObject->start(program, mode));
|
|
|
}
|
|
|
|
|
|
void PythonQtWrapper_QProcess::setProcessChannelMode(QProcess* theWrappedObject, QProcess::ProcessChannelMode mode)
|
|
|
{
|
|
|
( theWrappedObject->setProcessChannelMode(mode));
|
|
|
}
|
|
|
|
|
|
void PythonQtWrapper_QProcess::close(QProcess* theWrappedObject)
|
|
|
{
|
|
|
( ((PythonQtPublicPromoter_QProcess*)theWrappedObject)->promoted_close());
|
|
|
}
|
|
|
|
|
|
QStringList PythonQtWrapper_QProcess::static_QProcess_systemEnvironment()
|
|
|
{
|
|
|
return (QProcess::systemEnvironment());
|
|
|
}
|
|
|
|
|
|
void PythonQtWrapper_QProcess::setupChildProcess(QProcess* theWrappedObject)
|
|
|
{
|
|
|
( ((PythonQtPublicPromoter_QProcess*)theWrappedObject)->promoted_setupChildProcess());
|
|
|
}
|
|
|
|
|
|
void PythonQtWrapper_QProcess::setReadChannel(QProcess* theWrappedObject, QProcess::ProcessChannel channel)
|
|
|
{
|
|
|
( theWrappedObject->setReadChannel(channel));
|
|
|
}
|
|
|
|
|
|
QProcess::ProcessState PythonQtWrapper_QProcess::state(QProcess* theWrappedObject) const
|
|
|
{
|
|
|
return ( theWrappedObject->state());
|
|
|
}
|
|
|
|
|
|
bool PythonQtWrapper_QProcess::canReadLine(QProcess* theWrappedObject) const
|
|
|
{
|
|
|
return ( ((PythonQtPublicPromoter_QProcess*)theWrappedObject)->promoted_canReadLine());
|
|
|
}
|
|
|
|
|
|
void PythonQtWrapper_QProcess::closeWriteChannel(QProcess* theWrappedObject)
|
|
|
{
|
|
|
( theWrappedObject->closeWriteChannel());
|
|
|
}
|
|
|
|
|
|
QProcess::ProcessChannelMode PythonQtWrapper_QProcess::processChannelMode(QProcess* theWrappedObject) const
|
|
|
{
|
|
|
return ( theWrappedObject->processChannelMode());
|
|
|
}
|
|
|
|
|
|
void PythonQtWrapper_QProcess::setStandardOutputFile(QProcess* theWrappedObject, const QString& fileName, QIODevice::OpenMode mode)
|
|
|
{
|
|
|
( theWrappedObject->setStandardOutputFile(fileName, mode));
|
|
|
}
|
|
|
|
|
|
bool PythonQtWrapper_QProcess::atEnd(QProcess* theWrappedObject) const
|
|
|
{
|
|
|
return ( ((PythonQtPublicPromoter_QProcess*)theWrappedObject)->promoted_atEnd());
|
|
|
}
|
|
|
|
|
|
QProcess::ExitStatus PythonQtWrapper_QProcess::exitStatus(QProcess* theWrappedObject) const
|
|
|
{
|
|
|
return ( theWrappedObject->exitStatus());
|
|
|
}
|
|
|
|
|
|
QByteArray PythonQtWrapper_QProcess::readAllStandardOutput(QProcess* theWrappedObject)
|
|
|
{
|
|
|
return ( theWrappedObject->readAllStandardOutput());
|
|
|
}
|
|
|
|
|
|
qint64 PythonQtWrapper_QProcess::writeData(QProcess* theWrappedObject, const char* data, qint64 len)
|
|
|
{
|
|
|
return ( ((PythonQtPublicPromoter_QProcess*)theWrappedObject)->promoted_writeData(data, len));
|
|
|
}
|
|
|
|
|
|
void PythonQtWrapper_QProcess::setEnvironment(QProcess* theWrappedObject, const QStringList& environment)
|
|
|
{
|
|
|
( theWrappedObject->setEnvironment(environment));
|
|
|
}
|
|
|
|
|
|
qint64 PythonQtWrapper_QProcess::bytesToWrite(QProcess* theWrappedObject) const
|
|
|
{
|
|
|
return ( ((PythonQtPublicPromoter_QProcess*)theWrappedObject)->promoted_bytesToWrite());
|
|
|
}
|
|
|
|
|
|
void PythonQtWrapper_QProcess::setWorkingDirectory(QProcess* theWrappedObject, const QString& dir)
|
|
|
{
|
|
|
( theWrappedObject->setWorkingDirectory(dir));
|
|
|
}
|
|
|
|
|
|
|