hpp-corbaserver  4.11.0
Corba server for Humanoid Path Planner applications
paths.hh
Go to the documentation of this file.
1 #ifndef hpp_core_idl__paths_hxx__
2 #define hpp_core_idl__paths_hxx__
3 
4 //
5 // Implemention of IDL interfaces in file /local/robotpkg/var/tmp/robotpkg/path/py-hpp-corbaserver/work/hpp-corbaserver-4.11.0/idl/hpp/core_idl/paths.idl
6 //
7 
9 
10 #include <sstream>
11 
12 #include <hpp/corbaserver/fwd.hh>
15 
16 
17 
18 //
19 // Implementational code for IDL interface hpp::core_idl::Path
20 //
21 namespace hpp {
22 
23 namespace core_impl {
24 template <typename _Base, typename _Storage>
26  : hpp::corbaServer::ServantBase<hpp::core::Path, _Storage> (server, s)
27 {
28  // add extra constructor code here
29 }
30 template <typename _Base, typename _Storage>
32 {
33  // add extra destructor code here
34 }
35 
36 // Methods corresponding to IDL attributes and operations
37 
38 template <typename _Base, typename _Storage>
40 {
41  try {
42  // automatically generated code.
43  _ServantBase::deleteThis();
44  } catch (const std::exception& e) {
45  throw ::hpp::Error (e.what());
46  }
47 }
48 
49 template <typename _Base, typename _Storage>
51 {
52  try {
53  // automatically generated code.
54 
55  hpp::size_type __return__ (getT()->outputSize ());
56 
57  return __return__;
58  } catch (const std::exception& e) {
59  throw ::hpp::Error (e.what());
60  }
61 }
62 
63 template <typename _Base, typename _Storage>
65 {
66  try {
67  // automatically generated code.
68 
69  hpp::size_type __return__ (getT()->outputDerivativeSize ());
70 
71  return __return__;
72  } catch (const std::exception& e) {
73  throw ::hpp::Error (e.what());
74  }
75 }
76 
77 template <typename _Base, typename _Storage>
79 {
80  try {
81  // automatically generated code.
82 
83  hpp::value_type __return__ (getT()->length ());
84 
85  return __return__;
86  } catch (const std::exception& e) {
87  throw ::hpp::Error (e.what());
88  }
89 }
90 
91 template <typename _Base, typename _Storage>
93 {
94  try {
95  // automatically generated code.
96 
98 
99  return __return__;
100  } catch (const std::exception& e) {
101  throw ::hpp::Error (e.what());
102  }
103 }
104 
105 template <typename _Base, typename _Storage>
107 {
108  try {
109  // automatically generated code.
110 
112 
113  return __return__;
114  } catch (const std::exception& e) {
115  throw ::hpp::Error (e.what());
116  }
117 }
118 
119 template <typename _Base, typename _Storage>
121 {
122  try {
123  // automatically generated code.
124 
125  hpp::core::ConstraintSetPtr_t __return__ (getT()->constraints ());
126 
127  return ::hpp::corbaServer::makeServantDownCast<hpp::core_impl::Constraint,hpp::core_impl::ConstraintSet>(server_, __return__)._retn();
128  } catch (const std::exception& e) {
129  throw ::hpp::Error (e.what());
130  }
131 }
132 
133 template <typename _Base, typename _Storage>
135 {
136  try {
137  // automatically generated code.
138  std::ostringstream oss; oss << *get();
139  std::string res = oss.str();
140  return CORBA::string_dup(res.c_str());
141  } catch (const std::exception& e) {
142  throw ::hpp::Error (e.what());
143  }
144 }
145 
146 template <typename _Base, typename _Storage>
148 {
149  try {
150  // automatically generated code.
151 
152  hpp::floatSeq* __return__ = hpp::corbaServer::vectorToFloatSeq (getT()->eval (t, success));
153 
154  return __return__;
155  } catch (const std::exception& e) {
156  throw ::hpp::Error (e.what());
157  }
158 }
159 
160 template <typename _Base, typename _Storage>
162 {
163  try {
164  // generated from /local/robotpkg/var/tmp/robotpkg/path/py-hpp-corbaserver/work/hpp-corbaserver-4.11.0/idl/hpp/core_idl/paths.idl:23
165  hpp::core::vector_t res (get()->outputSize());
166  success = get()->at (t, res);
168 
169  } catch (const std::exception& e) {
170  throw ::hpp::Error (e.what());
171  }
172 }
173 
174 template <typename _Base, typename _Storage>
176 {
177  try {
178  // generated from /local/robotpkg/var/tmp/robotpkg/path/py-hpp-corbaserver/work/hpp-corbaserver-4.11.0/idl/hpp/core_idl/paths.idl:23
180  get()->derivative (res, t, order);
182 
183  } catch (const std::exception& e) {
184  throw ::hpp::Error (e.what());
185  }
186 }
187 
188 template <typename _Base, typename _Storage>
190 {
191  try {
192  // automatically generated code.
193 
194  hpp::core::PathPtr_t __return__ (getT()->extract (tmin, tmax));
195 
196  return ::hpp::corbaServer::makeServantDownCast<hpp::core_impl::Path,hpp::core_impl::Path>(server_, __return__)._retn();
197  } catch (const std::exception& e) {
198  throw ::hpp::Error (e.what());
199  }
200 }
201 
202 template <typename _Base, typename _Storage>
204 {
205  try {
206  // generated from /local/robotpkg/var/tmp/robotpkg/path/py-hpp-corbaserver/work/hpp-corbaserver-4.11.0/idl/hpp/core_idl/paths.idl:23
207  hpp::core::PathPtr_t p = get();
209  hpp::core::PathVector::create (p->outputSize(), p->outputDerivativeSize());
210  pv->appendPath (p);
211 
212  return hpp::corbaServer::makeServant<hpp::core_idl::PathVector_ptr>
213  (server_, new PathVector (server_, pv));
214 
215  } catch (const std::exception& e) {
216  throw ::hpp::Error (e.what());
217  }
218 }
219 
220 template <typename _Base, typename _Storage>
222 {
223  try {
224  // automatically generated code.
225 
226  hpp::core::PathPtr_t __return__ (getT()->reverse ());
227 
228  return ::hpp::corbaServer::makeServantDownCast<hpp::core_impl::Path,hpp::core_impl::Path>(server_, __return__)._retn();
229  } catch (const std::exception& e) {
230  throw ::hpp::Error (e.what());
231  }
232 }
233 
234 // End of implementational code
235 } // namespace core_impl
236 
237 } // namespace hpp
238 
239 //
240 // Implementational code for IDL interface hpp::core_idl::PathVector
241 //
242 namespace hpp {
243 
244 namespace core_impl {
245 template <typename _Base, typename _Storage>
247  : hpp::core_impl::PathServant<_Base, _Storage> (server, s)
248 {
249  // add extra constructor code here
250 }
251 template <typename _Base, typename _Storage>
253 {
254  // add extra destructor code here
255 }
256 
257 // Methods corresponding to IDL attributes and operations
258 
259 template <typename _Base, typename _Storage>
261 {
262  try {
263  // automatically generated code.
264 
265  hpp::core_idl::size_t __return__ (getT()->numberPaths ());
266 
267  return __return__;
268  } catch (const std::exception& e) {
269  throw ::hpp::Error (e.what());
270  }
271 }
272 
273 template <typename _Base, typename _Storage>
275 {
276  try {
277  // automatically generated code.
278 
279  hpp::core_idl::size_t __return__ (getT()->rankAtParam (param, localParam));
280 
281  return __return__;
282  } catch (const std::exception& e) {
283  throw ::hpp::Error (e.what());
284  }
285 }
286 
287 template <typename _Base, typename _Storage>
289 {
290  try {
291  // automatically generated code.
292 
293  hpp::core::PathPtr_t __return__ (getT()->pathAtRank (rank));
294 
295  return ::hpp::corbaServer::makeServantDownCast<hpp::core_impl::Path,hpp::core_impl::Path>(server_, __return__)._retn();
296  } catch (const std::exception& e) {
297  throw ::hpp::Error (e.what());
298  }
299 }
300 
301 template <typename _Base, typename _Storage>
303 {
304  try {
305  // automatically generated code.
306  hpp::core::PathPtr_t _p = ::hpp::corbaServer::reference_to_object<hpp::core::Path>(server_, p);
307  (getT()->appendPath (_p));
308 
309 
310  } catch (const std::exception& e) {
311  throw ::hpp::Error (e.what());
312  }
313 }
314 
315 template <typename _Base, typename _Storage>
317 {
318  try {
319  // automatically generated code.
320  hpp::core::PathVectorPtr_t _p = ::hpp::corbaServer::reference_to_object<hpp::core::PathVector>(server_, p);
321  (getT()->concatenate (_p));
322 
323 
324  } catch (const std::exception& e) {
325  throw ::hpp::Error (e.what());
326  }
327 }
328 
329 // End of implementational code
330 } // namespace core_impl
331 
332 } // namespace hpp
333 
334 
335 
336 
337 
338 #endif // hpp_core_idl__paths_hxx__
339 
PathVectorServant< POA_hpp::core_idl::PathVector, hpp::weak_ptr< hpp::core::PathVector > > PathVector
Definition: paths-fwd.hh:133
Definition: paths-fwd.hh:26
hpp::floatSeq * at(hpp::value_type t, ::CORBA::Boolean &success)
Definition: paths.hh:161
virtual ~PathServant()
Definition: paths.hh:31
Implement CORBA interface ``Obstacle&#39;&#39;.
Definition: basic-server.hh:27
hpp::floatSeq * initial()
Definition: paths.hh:92
double value_type
Definition: common.idl:18
unsigned long long size_t
Definition: paths.idl:18
hpp::floatSeq * end()
Definition: paths.hh:106
PathServant(::hpp::corbaServer::Server *server, const _Storage &s)
Definition: paths.hh:25
hpp::value_type length()
Definition: paths.hh:78
void deleteThis()
Definition: paths.hh:39
Server * server_
Definition: servant-base.hh:97
void appendPath(hpp::core_idl::Path_ptr p)
Definition: paths.hh:302
pinocchio::vector_t vector_t
Definition: fwd.hh:89
PathVectorServant(::hpp::corbaServer::Server *server, const _Storage &s)
Definition: paths.hh:246
hpp::core_idl::PathVector_ptr asVector()
Definition: paths.hh:203
hpp::core_idl::Path_ptr reverse()
Definition: paths.hh:221
_objref_PathVector * PathVector_ptr
Definition: paths-idl.hh:82
virtual ~PathVectorServant()
Definition: paths.hh:252
hpp::core_idl::ConstraintSet_ptr constraints()
Definition: paths.hh:120
core::PathVectorPtr_t PathVectorPtr_t
Definition: fwd.hh:77
hpp::floatSeq * derivative(hpp::value_type t, ::CORBA::Short order)
Definition: paths.hh:175
hpp::floatSeq * call(hpp::value_type t, ::CORBA::Boolean &success)
Definition: paths.hh:147
Implementation of Hpp module Corba server.
Definition: server.hh:54
hpp::size_type outputSize()
Definition: paths.hh:50
_objref_ConstraintSet * ConstraintSet_ptr
Definition: _constraints-idl.hh:480
char * str()
Definition: paths.hh:134
floatSeq * vectorToFloatSeq(core::vectorIn_t input)
hpp::size_type outputDerivativeSize()
Definition: paths.hh:64
void concatenate(hpp::core_idl::PathVector_ptr p)
Definition: paths.hh:316
StorageElementShPtr_t getT() const
Definition: servant-base.hh:121
hpp::core_idl::Path_ptr extract(hpp::value_type tmin, hpp::value_type tmax)
Definition: paths.hh:189
_objref_Path * Path_ptr
Definition: path_planners-idl.hh:83
sequence< double > floatSeq
Robot configuration is defined by a sequence of dof value.
Definition: common.idl:33
hpp::core_idl::size_t numberPaths()
Definition: paths.hh:260
core::PathPtr_t PathPtr_t
Definition: fwd.hh:74
hpp::core_idl::size_t rankAtParam(hpp::value_type param, hpp::value_type &localParam)
Definition: paths.hh:274
long long size_type
Definition: common.idl:19
hpp::core_idl::Path_ptr pathAtRank(hpp::core_idl::size_t rank)
Definition: paths.hh:288