source: icGREP/icgrep-devel/icgrep/grep_engine.h @ 5425

Last change on this file since 5425 was 5425, checked in by nmedfort, 2 years ago

Changes towards separate compilation

File size: 1.3 KB
RevLine 
[4324]1/*
[4947]2 *  Copyright (c) 2016 International Characters.
[4324]3 *  This software is licensed to the public under the Open Software License 3.0.
4 *  icgrep is a trademark of International Characters.
5 */
[5267]6#ifndef DO_GREP_H
7#define DO_GREP_H
8#include <grep_type.h>  // for GrepType, GrepType::Normal
9#include <string>       // for string
10#include <vector>
11namespace llvm { class ExecutionEngine; }
12namespace llvm { class Module; }
13namespace re { class CC; }
14namespace re { class RE; }
[4324]15
[5406]16class GrepEngine {
[4659]17public:
[4324]18
[5240]19    GrepEngine();
[5401]20
[5425]21    void grepCodeGen(const std::string & moduleName, std::vector<re::RE *> REs, bool CountOnly, bool UTF_16, GrepSource grepSource, GrepType grepType = GrepType::Normal);
[5398]22
[5419]23    uint64_t doGrep(const std::string & fileName, const uint32_t fileIdx) const;
[5377]24
[5419]25    uint64_t doGrep(const int32_t fileDescriptor, const uint32_t fileIdx) const;
[4949]26   
[5419]27    void doGrep(const char * buffer, const uint64_t length, const uint32_t fileIdx) const;
[5267]28
[5418]29    re::CC * grepCodepoints();
30
[5267]31    const std::vector<std::string> & grepPropertyValues(const std::string & propertyName);
[4946]32   
[4324]33private:
[4939]34   
[5418]35    void * mGrepFunction;
[4324]36};
37
38
[5033]39re::CC * getParsedCodePointSet();
40void setParsedCodePointSet();
41
[5206]42void setParsedPropertyValues();
43
[5377]44void initFileResult(std::vector<std::string> filenames);
[5107]45void PrintResult(bool CountOnly, std::vector<size_t> & total_CountOnly);
[5033]46
[4324]47#endif
Note: See TracBrowser for help on using the repository browser.