2024-08-25 04:08:24 +00:00
|
|
|
#include <QByteArray>
|
|
|
|
#include <QByteArrayMatcher>
|
|
|
|
#include <QStaticByteArrayMatcherBase>
|
2024-08-29 07:01:51 +00:00
|
|
|
#include "qbytearraymatcher.h"
|
|
|
|
#include "gen_qbytearraymatcher.h"
|
2024-09-14 22:29:05 +00:00
|
|
|
#include "_cgo_export.h"
|
2024-08-25 04:08:24 +00:00
|
|
|
|
|
|
|
QByteArrayMatcher* QByteArrayMatcher_new() {
|
|
|
|
return new QByteArrayMatcher();
|
|
|
|
}
|
|
|
|
|
|
|
|
QByteArrayMatcher* QByteArrayMatcher_new2(QByteArray* pattern) {
|
|
|
|
return new QByteArrayMatcher(*pattern);
|
|
|
|
}
|
|
|
|
|
2024-08-29 07:01:51 +00:00
|
|
|
QByteArrayMatcher* QByteArrayMatcher_new3(const char* pattern, int length) {
|
2024-08-25 04:08:24 +00:00
|
|
|
return new QByteArrayMatcher(pattern, static_cast<int>(length));
|
|
|
|
}
|
|
|
|
|
|
|
|
QByteArrayMatcher* QByteArrayMatcher_new4(QByteArrayMatcher* other) {
|
|
|
|
return new QByteArrayMatcher(*other);
|
|
|
|
}
|
|
|
|
|
|
|
|
void QByteArrayMatcher_OperatorAssign(QByteArrayMatcher* self, QByteArrayMatcher* other) {
|
|
|
|
self->operator=(*other);
|
|
|
|
}
|
|
|
|
|
|
|
|
void QByteArrayMatcher_SetPattern(QByteArrayMatcher* self, QByteArray* pattern) {
|
|
|
|
self->setPattern(*pattern);
|
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
int QByteArrayMatcher_IndexIn(const QByteArrayMatcher* self, QByteArray* ba) {
|
|
|
|
return self->indexIn(*ba);
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
int QByteArrayMatcher_IndexIn2(const QByteArrayMatcher* self, const char* str, int lenVal) {
|
|
|
|
return self->indexIn(str, static_cast<int>(lenVal));
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
QByteArray* QByteArrayMatcher_Pattern(const QByteArrayMatcher* self) {
|
2024-09-17 06:29:11 +00:00
|
|
|
return new QByteArray(self->pattern());
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
int QByteArrayMatcher_IndexIn22(const QByteArrayMatcher* self, QByteArray* ba, int from) {
|
|
|
|
return self->indexIn(*ba, static_cast<int>(from));
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
int QByteArrayMatcher_IndexIn3(const QByteArrayMatcher* self, const char* str, int lenVal, int from) {
|
|
|
|
return self->indexIn(str, static_cast<int>(lenVal), static_cast<int>(from));
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void QByteArrayMatcher_Delete(QByteArrayMatcher* self) {
|
|
|
|
delete self;
|
|
|
|
}
|
|
|
|
|
|
|
|
void QStaticByteArrayMatcherBase_Delete(QStaticByteArrayMatcherBase* self) {
|
|
|
|
delete self;
|
|
|
|
}
|
|
|
|
|