45 #include "telCoreExporter.h"
46 #include "telPluginsManagerSettings.h"
47 #include "telProperties.h"
57 using tlp::gEmptyString;
58 using tlp::gNoneString;
65 typedef void (event_cc *PluginEvent)(
void* data1,
void* data2);
99 Plugin(
const string& name = gEmptyString,
100 const string& cat = gNoneString,
101 RoadRunner* aRR = NULL,
102 const string& language = gNoneString,
118 string getLibraryName();
128 string getCategory();
133 string getDescription();
148 string getCopyright();
153 RoadRunner* getRoadRunnerInstance();
158 virtual string getInfo();
163 virtual string getExtendedInfo();
168 virtual unsigned char* getManualAsPDF()
const;
173 virtual unsigned int getPDFManualByteSize();
178 virtual Properties* getProperties();
183 virtual tlp::StringList getPropertyNames();
188 string getPluginPropertiesAsXML();
193 virtual PropertyBase* getProperty(
const string& param);
198 string getPropertyValueAsString(
const string& param);
203 void* getPropertyValueHandle(
const string& param);
208 void setPropertyByString(
const string& nameOf,
const char* value);
213 void setPropertyValue(
const string& nameOf,
const void* value);
223 bool isBeingTerminated()
const;
226 bool wasTerminated()
const;
229 virtual bool isWorking()
const;
232 virtual bool assignRoadRunnerInstance(RoadRunner* rr);
237 virtual bool assignOnStartedEvent(PluginEvent pluginStarted,
void* userData1 = NULL,
void* userData2 = NULL);
242 virtual bool assignOnProgressEvent(PluginEvent pluginsProgress,
void* userData1 = NULL,
void* userData2 = NULL);
247 virtual bool assignOnFinishedEvent(PluginEvent pluginsFinished,
void* userData1 = NULL,
void* userData2 = NULL);
252 virtual string getResult();
257 virtual bool resetPlugin();
262 virtual string getStatus();
267 virtual string getImplementationLanguage() = 0;
273 bool hasStartedEvent()
const;
278 bool hasProgressEvent()
const;
283 bool hasFinishedEvent()
const;
288 void WorkStartedEvent(
void* data1,
void* data2);
293 void WorkProgressEvent(
void* data1,
void* data2);
298 void WorkFinishedEvent(
void* data1,
void* data2);
303 pair<void*, void*> getWorkStartedData();
308 pair<void*, void*> getWorkProgressData();
313 pair<void*, void*> getWorkFinishedData();
318 virtual bool execute(
bool inAThread =
false) = 0;
374 void setLibraryName(
const string& libName);