Main Page
Related Pages
Modules
Namespaces
Classes
Files
Examples
File List
File Members
rtt
scripting
ArgumentsParser.hpp
Go to the documentation of this file.
1
/***************************************************************************
2
tag: Peter Soetens Mon Jan 19 14:11:26 CET 2004 ArgumentsParser.hpp
3
4
ArgumentsParser.hpp - description
5
-------------------
6
begin : Mon January 19 2004
7
copyright : (C) 2004 Peter Soetens
8
email : peter.soetens@mech.kuleuven.ac.be
9
10
***************************************************************************
11
* This library is free software; you can redistribute it and/or *
12
* modify it under the terms of the GNU General Public *
13
* License as published by the Free Software Foundation; *
14
* version 2 of the License. *
15
* *
16
* As a special exception, you may use this file as part of a free *
17
* software library without restriction. Specifically, if other files *
18
* instantiate templates or use macros or inline functions from this *
19
* file, or you compile this file and link it with other files to *
20
* produce an executable, this file does not by itself cause the *
21
* resulting executable to be covered by the GNU General Public *
22
* License. This exception does not however invalidate any other *
23
* reasons why the executable file might be covered by the GNU General *
24
* Public License. *
25
* *
26
* This library is distributed in the hope that it will be useful, *
27
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
28
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
29
* Lesser General Public License for more details. *
30
* *
31
* You should have received a copy of the GNU General Public *
32
* License along with this library; if not, write to the Free Software *
33
* Foundation, Inc., 59 Temple Place, *
34
* Suite 330, Boston, MA 02111-1307 USA *
35
* *
36
***************************************************************************/
37
38
#ifndef ARGUMENTSPARSER_HPP
39
#define ARGUMENTSPARSER_HPP
40
41
#include "
parser-types.hpp
"
42
43
#include "../PropertyBag.hpp"
44
#include "
CommonParser.hpp
"
45
#include "../TaskContext.hpp"
46
47
#ifdef ORO_PRAGMA_INTERFACE
48
#pragma interface
49
#endif
50
51
namespace
RTT
{
namespace
scripting
52
{
53
54
55
66
class
ArgumentsParser
67
{
68
// the arguments we have already parsed.
69
std::vector<base::DataSourceBase::shared_ptr>
margs
;
70
bool
mparsed
;
71
72
rule_t
arguments
,
argument
;
73
74
ExpressionParser
&
expressionparser
;
75
76
void
seen_arg
();
77
void
seenarguments
();
78
79
std::string
mobject
;
80
std::string
mmethod
;
81
TaskContext
*
_peer
;
82
Service::shared_ptr
mtobject
;
83
public
:
89
ArgumentsParser
(
ExpressionParser
& p,
TaskContext
*
peer
,
Service::shared_ptr
tobject,
90
const
std::string&
object
,
const
std::string& method );
91
92
~ArgumentsParser
();
93
94
TaskContext
*
peer
()
95
{
96
return
_peer
;
97
}
98
99
Service::shared_ptr
object
()
100
{
101
return
mtobject
;
102
}
103
104
rule_t
&
parser
()
105
{
106
return
arguments
;
107
}
108
112
std::vector<base::DataSourceBase::shared_ptr>
result
()
113
{
114
return
margs
;
115
}
121
bool
parsed
()
const
122
{
123
return
mparsed
;
124
}
125
126
std::string
objectname
()
127
{
128
return
mobject
;
129
}
130
std::string
methodname
()
131
{
132
return
mmethod
;
133
}
134
};
135
}}
136
137
#endif
RTT::scripting::ArgumentsParser::result
std::vector< base::DataSourceBase::shared_ptr > result()
Definition:
ArgumentsParser.hpp:112
RTT::scripting::ArgumentsParser::parser
rule_t & parser()
Definition:
ArgumentsParser.hpp:104
RTT::scripting::ArgumentsParser::margs
std::vector< base::DataSourceBase::shared_ptr > margs
Definition:
ArgumentsParser.hpp:69
RTT::scripting::ArgumentsParser::peer
TaskContext * peer()
Definition:
ArgumentsParser.hpp:94
RTT::scripting::ArgumentsParser::mtobject
Service::shared_ptr mtobject
Definition:
ArgumentsParser.hpp:82
RTT::scripting::ArgumentsParser::ArgumentsParser
ArgumentsParser(ExpressionParser &p, TaskContext *peer, Service::shared_ptr tobject, const std::string &object, const std::string &method)
Definition:
ArgumentsParser.cpp:62
RTT::scripting::ArgumentsParser::expressionparser
ExpressionParser & expressionparser
Definition:
ArgumentsParser.hpp:74
RTT::scripting::ArgumentsParser
Definition:
ArgumentsParser.hpp:66
RTT::scripting::ArgumentsParser::arguments
rule_t arguments
Definition:
ArgumentsParser.hpp:72
RTT::Service::shared_ptr
boost::shared_ptr< Service > shared_ptr
Definition:
Service.hpp:101
RTT::scripting::ExpressionParser
Definition:
ExpressionParser.hpp:146
RTT::scripting::ArgumentsParser::mobject
std::string mobject
Definition:
ArgumentsParser.hpp:79
RTT::scripting::ArgumentsParser::methodname
std::string methodname()
Definition:
ArgumentsParser.hpp:130
RTT::scripting::ArgumentsParser::~ArgumentsParser
~ArgumentsParser()
Definition:
ArgumentsParser.cpp:96
RTT::scripting::rule_t
rule< scanner_t > rule_t
Definition:
parser-types.hpp:173
parser-types.hpp
RTT::scripting::ArgumentsParser::mparsed
bool mparsed
Definition:
ArgumentsParser.hpp:70
RTT::scripting::ArgumentsParser::argument
rule_t argument
Definition:
ArgumentsParser.hpp:72
RTT::scripting::ArgumentsParser::mmethod
std::string mmethod
Definition:
ArgumentsParser.hpp:80
RTT::scripting::ArgumentsParser::seenarguments
void seenarguments()
Definition:
ArgumentsParser.cpp:91
RTT::scripting::ArgumentsParser::seen_arg
void seen_arg()
Definition:
ArgumentsParser.cpp:85
RTT::scripting::ArgumentsParser::parsed
bool parsed() const
Definition:
ArgumentsParser.hpp:121
RTT::TaskContext
Definition:
TaskContext.hpp:93
RTT::scripting::ArgumentsParser::object
Service::shared_ptr object()
Definition:
ArgumentsParser.hpp:99
RTT
Contains TaskContext, Activity, OperationCaller, Operation, Property, InputPort, OutputPort, Attribute.
Definition:
Activity.cpp:53
RTT::scripting::ArgumentsParser::_peer
TaskContext * _peer
Definition:
ArgumentsParser.hpp:81
RTT::scripting::ArgumentsParser::objectname
std::string objectname()
Definition:
ArgumentsParser.hpp:126
CommonParser.hpp
rtt
Author(s): RTT Developers
autogenerated on Fri Oct 25 2019 03:59:30