28 lines
878 B
C++
28 lines
878 B
C++
#pragma once
|
|
|
|
#include <QFileInfoList>
|
|
#include <ast_gen.h>
|
|
#include <libsyntax.h>
|
|
#include <libparse.h>
|
|
|
|
namespace example_novel {
|
|
class FragmentGraphHelper;
|
|
}
|
|
|
|
class NovelParser
|
|
{
|
|
private:
|
|
std::shared_ptr<ast_gen::GlobalElement> context = nullptr;
|
|
std::shared_ptr<const ExprRule> syntax_defines;
|
|
QList<std::shared_ptr<const lib_parse::CheckProvider>> checker_list;
|
|
std::shared_ptr<const lib_parse::Analyzer> analyzer_ref;
|
|
|
|
public:
|
|
NovelParser();
|
|
QList<std::shared_ptr<const example_novel::FragmentGraphHelper>> fragmentsSorted() const;
|
|
|
|
virtual QString version() const;
|
|
std::shared_ptr<IContext> parserContext() const;
|
|
QList<std::shared_ptr<const IExprInstance>> parse(const QFileInfoList souurce_list) const;
|
|
std::shared_ptr<const ast_gen::ElementAccess> validsApply(QList<std::shared_ptr<const IExprInstance>> docs_list) const;
|
|
}; |