ADTF
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
scriptable_intf.h
Go to the documentation of this file.
1
7
8#ifndef _ADTF_UCOM_ANT_SCRIPTABLE_INTERFACE_INCLUDES_HEADER_
9#define _ADTF_UCOM_ANT_SCRIPTABLE_INTERFACE_INCLUDES_HEADER_
10
11namespace adtf
12{
13namespace ucom
14{
15namespace ant
16{
17
26class DOEXPORT IScriptable : public IObject
27{
28public:
33 ADTF_IID(IScriptable, "scriptable.ant.ucom.adtf.iid");
34
35 public:
37 typedef const char* tScriptArgs;
38
39 public:
51 virtual tResult ScriptRunCommand(const char* strCommand,
52 void* pvData=NULL,
53 int szData=0) = 0;
54
55
56 protected:
58 ~IScriptable() = default;
59};
60
62#define __script_cmd0(cmd) "<cmd name=\"" cmd "\" />"
63
65#define __script_cmd1(cmd \
66 , arg_name1, arg_value1 \
67 ) \
68 "<cmd name=" #cmd " " \
69 #arg_name1 "=" #arg_value1 " " \
70 "/>"
71
73#define __script_cmd2(cmd \
74 , arg_name1, arg_value1 \
75 , arg_name2, arg_value2 \
76 ) \
77 "<cmd name=" #cmd " " \
78 #arg_name1 "=" #arg_value1 " " \
79 #arg_name2 "=" #arg_value2 " " \
80 "/>"
81
83#define __script_cmd3(cmd \
84 , arg_name1, arg_value1 \
85 , arg_name2, arg_value2 \
86 , arg_name3, arg_value3 \
87 ) \
88 "<cmd name=" #cmd " " \
89 #arg_name1 "=" #arg_value1 " " \
90 #arg_name2 "=" #arg_value2 " " \
91 #arg_name3 "=" #arg_value3 " " \
92 "/>"
93
94}//namespace ant
95
98
99}//namespace ucom
100}//namespace adtf
101
102//*************************************************************************************************
103#endif //_ADTF_UCOM_ANT_SCRIPTABLE_INTERFACE_INCLUDES_HEADER_
A_UTILS_NS::cResult tResult
For backwards compatibility and to bring latest version into scope.
Base class for every interface type within the uCOM.
Definition object_intf.h:33
The IScriptable interface provides a generic way to implement scripting capabilities.
ADTF_IID(IScriptable, "scriptable.ant.ucom.adtf.iid")
Marks the IScriptable to be castable with the ucom_cast<>
~IScriptable()=default
Protected destructor --> Only the final implementation can be destroyed!
virtual tResult ScriptRunCommand(const char *strCommand, void *pvData=NULL, int szData=0)=0
Run script command.
const char * tScriptArgs
Standard scripting argument type.
Namespace for all functionality provided since v3.0.
Namespace for the ADTF uCOM3 SDK.
ant::IScriptable IScriptable
Alias always bringing the latest version of IScriptable into scope.
Namespace for entire ADTF SDK.