fixup! shared: processors: Use DocumentProcessResult instead of PageData vector

Esse commit está contido em:
Albert S. 2023-05-14 14:19:28 +02:00
commit f4eed7a6ef
2 arquivos alterados com 4 adições e 4 exclusões

Ver arquivo

@ -10,7 +10,7 @@ class NothingProcessor : public Processor
NothingProcessor(); NothingProcessor();
public: public:
QVector<PageData> process(const QByteArray & /*data*/) const override DocumentProcessResult process(const QByteArray & /*data*/) const override
{ {
return {}; return {};
} }

Ver arquivo

@ -2,8 +2,8 @@
#define PROCESSOR_H #define PROCESSOR_H
#include <QVector> #include <QVector>
#include <QFile> #include <QFile>
#include "pagedata.h"
#include "utils.h" #include "utils.h"
#include "documentprocessresult.h"
enum DataSource enum DataSource
{ {
FILEPATH, FILEPATH,
@ -18,8 +18,8 @@ class Processor
* a single file */ * a single file */
DataSource PREFERED_DATA_SOURCE = ARRAY; DataSource PREFERED_DATA_SOURCE = ARRAY;
Processor(); Processor();
virtual QVector<PageData> process(const QByteArray &data) const = 0; virtual DocumentProcessResult process(const QByteArray &data) const = 0;
virtual QVector<PageData> process(QString path) const virtual DocumentProcessResult process(QString path) const
{ {
return process(Utils::readFile(path)); return process(Utils::readFile(path));
} }