1 ///////////////////////////////////////////////////////////////////
2 // Automatically generated by xml2ulxr v1.7.5.
3 //
4 // xml2ulxr is part of Ultra Lightweight XML RPC for C++.
5 // See also http://ulxmlrpcpp.sourceforge.net
6 //
7 // Don't edit manually unless you know what you are doing
8 ///////////////////////////////////////////////////////////////////
9 
10 //#define ULXR_UNICODE_ONLY_HELPERS
11 #include <ulxmlrpcpp/ulxmlrpcpp.h> // always first
12 
13 #include "UlxrIdlTestFuncs_ulxr_server.h"
14 
15 #include <ulxmlrpcpp/ulxr_response.h>
16 #include <ulxmlrpcpp/ulxr_requester.h>
17 #include <ulxmlrpcpp/ulxr_except.h>
18 #include <ulxmlrpcpp/ulxr_method_adder.h>
19 
20 #include "UlxrIdlTestFuncs_ulxr_names.h"
21 #include "/home/ea/Documents/src/ulxmlrpcpp/trunk/ulxmlrpcpp/stubber/ulxr2xml/ulxridl_test.h"
22 
23 // mapped to: void funcs::free_function1(int i);   (there are overloaded methods)
24 ulxr::MethodResponse
UlxrIdlTestFuncs_funcs__free_function1_ovr0(const ulxr::MethodCall & calldata)25   UlxrIdlTestFuncs_funcs__free_function1_ovr0 (const ulxr::MethodCall &calldata)
26 {
27   try
28   {
29     int p0 = (int) ulxr::Integer(calldata.getParam(0)).getInteger();
30     funcs::free_function1(p0);
31     return ulxr::MethodResponse (ulxr::Void());
32   }
33   catch(std::exception &ex)
34   {
35     ulxr::CppString s = ULXR_PCHAR("C++ exception caught when invoking 'void funcs::free_function1(int i);'\n  ");
36     s += ULXR_GET_STRING(ex.what());
37     return ulxr::MethodResponse(ulxr::ApplicationError, s);
38   }
39   catch(...)
40   {
41     ulxr::CppString s = ULXR_PCHAR("Unknown exception caught when invoking 'void funcs::free_function1(int i);'");
42     return ulxr::MethodResponse(ulxr::ApplicationError, s);
43   }
44 }
45 
46 
47 // mapped to: long int funcs::free_function1(long int i, float f);   (there are overloaded methods)
48 ulxr::MethodResponse
UlxrIdlTestFuncs_funcs__free_function1_ovr1(const ulxr::MethodCall & calldata)49   UlxrIdlTestFuncs_funcs__free_function1_ovr1 (const ulxr::MethodCall &calldata)
50 {
51   try
52   {
53     long int p0 = (long int) ulxr::Integer(calldata.getParam(0)).getInteger();
54     float p1 = (float) ulxr::Double(calldata.getParam(1)).getDouble();
55     long int retval = funcs::free_function1(p0, p1);
56     return ulxr::MethodResponse (ulxr::Integer (retval));
57   }
58   catch(std::exception &ex)
59   {
60     ulxr::CppString s = ULXR_PCHAR("C++ exception caught when invoking 'long int funcs::free_function1(long int i, float f);'\n  ");
61     s += ULXR_GET_STRING(ex.what());
62     return ulxr::MethodResponse(ulxr::ApplicationError, s);
63   }
64   catch(...)
65   {
66     ulxr::CppString s = ULXR_PCHAR("Unknown exception caught when invoking 'long int funcs::free_function1(long int i, float f);'");
67     return ulxr::MethodResponse(ulxr::ApplicationError, s);
68   }
69 }
70 
71 
72 // mapped to: std::string * inline_func::free_function2(long int * i, float f);   (there are overloaded methods)
73 ulxr::MethodResponse
UlxrIdlTestFuncs_inline_func__free_function2(const ulxr::MethodCall & calldata)74   UlxrIdlTestFuncs_inline_func__free_function2 (const ulxr::MethodCall &calldata)
75 {
76   try
77   {
78     long int p0 = (long int) ulxr::Integer(calldata.getParam(0)).getInteger();
79     float p1 = (float) ulxr::Double(calldata.getParam(1)).getDouble();
80     std::string retval = *inline_func::free_function2(&p0, p1);
81     return ulxr::MethodResponse (ulxr::RpcString (ULXR_GET_STRING(retval)));
82   }
83   catch(std::exception &ex)
84   {
85     ulxr::CppString s = ULXR_PCHAR("C++ exception caught when invoking 'std::string * inline_func::free_function2(long int * i, float f);'\n  ");
86     s += ULXR_GET_STRING(ex.what());
87     return ulxr::MethodResponse(ulxr::ApplicationError, s);
88   }
89   catch(...)
90   {
91     ulxr::CppString s = ULXR_PCHAR("Unknown exception caught when invoking 'std::string * inline_func::free_function2(long int * i, float f);'");
92     return ulxr::MethodResponse(ulxr::ApplicationError, s);
93   }
94 }
95 
96 
97 
UlxrIdlTestFuncs_removeServerMethods(ulxr::MethodAdder & method_adder)98 void UlxrIdlTestFuncs_removeServerMethods(ulxr::MethodAdder &method_adder)
99 {
100   method_adder.removeMethod(ULXR_CALLTO_UlxrIdlTestFuncs_funcs__free_function1_ovr0);
101   method_adder.removeMethod(ULXR_CALLTO_UlxrIdlTestFuncs_funcs__free_function1_ovr1);
102   method_adder.removeMethod(ULXR_CALLTO_UlxrIdlTestFuncs_inline_func__free_function2);
103 }
104 
105