2018-11-03 17:12:20 +01:00
|
|
|
#ifndef PARSER_H
|
|
|
|
#define PARSER_H
|
|
|
|
#include "iparser.h"
|
|
|
|
|
2021-04-25 11:39:38 +02:00
|
|
|
class ParserLegacy : public IParser
|
2018-11-03 17:12:20 +01:00
|
|
|
{
|
|
|
|
private:
|
2020-03-18 22:00:15 +01:00
|
|
|
std::string processLink(const PageDao &pageDao, UrlProvider &urlProvider, std::smatch &match) const;
|
2018-11-03 17:12:20 +01:00
|
|
|
|
|
|
|
public:
|
2018-11-04 19:33:06 +01:00
|
|
|
std::string extractCommand(std::string cmdname, std::string content) const;
|
2018-11-03 17:12:20 +01:00
|
|
|
std::vector<Headline> extractHeadlines(std::string content) const override;
|
|
|
|
std::vector<std::string> extractCategories(std::string content) const override;
|
|
|
|
std::string parse(const PageDao &pagedao, UrlProvider &provider, std::string content) const override;
|
|
|
|
using IParser::IParser;
|
2021-04-25 11:39:38 +02:00
|
|
|
~ParserLegacy(){};
|
2018-11-03 17:12:20 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // PARSER_H
|