21#ifndef G_EXECUTABLE_FILTER_H
22#define G_EXECUTABLE_FILTER_H
37 class ExecutableFilter ;
47 const Filter::Config & ,
const std::string & path ) ;
54 std::string id()
const override ;
55 bool quiet()
const override ;
57 void start( const
GStore::MessageId & ) override ;
58 void cancel() override ;
59 Result result() const override ;
60 std::
string response() const override ;
61 int responseCode() const override ;
62 std::
string reason() const override ;
63 bool special() const override ;
64 void onTaskDone(
int , const
std::
string & ) override ;
73 static
std::tuple<
std::
string,
int,
std::
string> parseOutput(
std::
string , const
std::
string & ) ;
75 std::
string prefix() const ;
78 GStore::FileStore & m_file_store ;
79 G::Slot::Signal<
int> m_done_signal ;
80 Filter::Type m_filter_type ;
83 unsigned int m_timeout ;
85 std::
string m_response ;
86 int m_response_code {0} ;
87 std::string m_reason ;
A Filter class that runs an external helper program.
ExecutableFilter(GNet::EventState, GStore::FileStore &, Filter::Type, const Filter::Config &, const std::string &path)
Constructor.
~ExecutableFilter() override
Destructor.
A lightweight object containing an ExceptionHandler pointer, optional ExceptionSource pointer and opt...
An abstract interface for callbacks from GNet::Task.
A class for running an exectuable in a separate process with an asychronous completion callback.
An interface for processing a message file through a filter.
A concrete implementation of the MessageStore interface dealing in paired flat files.
Interprets an executable filter's exit code.