4
* Copyright Ericsson AB 2004-2011. All Rights Reserved.
6
* The contents of this file are subject to the Erlang Public License,
7
* Version 1.1, (the "License"); you may not use this file except in
8
* compliance with the License. You should have received a copy of the
9
* Erlang Public License along with this software. If not, it can be
10
* retrieved online at http://www.erlang.org/.
12
* Software distributed under the License is distributed on an "AS IS"
13
* basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
14
* the License for the specific language governing rights and limitations
28
#include <erl_interface.h>
36
void my_void_test(CORBA_Object oe_obj,
37
CORBA_Environment *oe_env)
39
/* printf("void test !\n"); */
42
m_i_void_test__rs* m_i_void_test__cb(CORBA_Object oe_obj,
43
CORBA_Environment *oe_env)
45
return (m_i_void_test__rs*) (my_void_test);
52
void my_long_test(CORBA_Object oe_obj,
56
CORBA_Environment *oe_env)
58
/* printf("long test !\n"); */
62
m_i_long_test__rs* m_i_long_test__cb(CORBA_Object oe_obj,
66
CORBA_Environment *oe_env)
70
return (m_i_long_test__rs*) (my_long_test);
75
void my_longlong_test(CORBA_Object oe_obj,
79
CORBA_Environment *oe_env)
81
/* printf("long test !\n"); */
84
m_i_longlong_test__rs* m_i_longlong_test__cb(CORBA_Object oe_obj,
88
CORBA_Environment *oe_env)
92
return (m_i_longlong_test__rs*) (my_longlong_test);
96
void my_ulong_test(CORBA_Object oe_obj,
100
CORBA_Environment *oe_env)
102
/* printf("ulong test !\n"); */
105
m_i_ulong_test__rs* m_i_ulong_test__cb(CORBA_Object oe_obj,
109
CORBA_Environment *oe_env)
113
return (m_i_ulong_test__rs*) (my_ulong_test);
117
void my_ulonglong_test(CORBA_Object oe_obj,
118
CORBA_unsigned_long_long* a,
119
CORBA_unsigned_long_long* b,
120
CORBA_unsigned_long_long* c,
121
CORBA_Environment *oe_env)
123
/* printf("ulong test !\n"); */
126
m_i_ulonglong_test__rs* m_i_ulonglong_test__cb(CORBA_Object oe_obj,
127
CORBA_unsigned_long_long* a,
128
CORBA_unsigned_long_long* b,
129
CORBA_unsigned_long_long* c,
130
CORBA_Environment *oe_env)
134
return (m_i_ulonglong_test__rs*) (my_ulonglong_test);
137
m_i_ushort_test__rs* m_i_ushort_test__cb(CORBA_Object oe_obj,
141
CORBA_Environment *oe_env)
145
return (m_i_ushort_test__rs*) NULL;
150
void my_double_test(CORBA_Object oe_obj,
154
CORBA_Environment *oe_env)
156
/* printf("double test !\n"); */
159
m_i_double_test__rs* m_i_double_test__cb(CORBA_Object oe_obj,
163
CORBA_Environment *oe_env)
167
return (m_i_double_test__rs*) (my_double_test);
171
m_i_char_test__rs* m_i_char_test__cb(CORBA_Object oe_obj,
175
CORBA_Environment *oe_env)
177
m_i_char_test__rs* rs = NULL;
186
m_i_wchar_test__rs* m_i_wchar_test__cb(CORBA_Object oe_obj,
190
CORBA_Environment *oe_env)
192
m_i_wchar_test__rs* rs = NULL;
200
m_i_octet_test__rs* m_i_octet_test__cb(CORBA_Object oe_obj,
204
CORBA_Environment *oe_env)
206
m_i_octet_test__rs* rs = NULL;
214
m_i_bool_test__rs* m_i_bool_test__cb(CORBA_Object oe_obj,
218
CORBA_Environment *oe_env)
220
m_i_bool_test__rs* rs = NULL;
228
void my_struct_test(CORBA_Object oe_obj,
232
CORBA_Environment *oe_env)
234
/* printf("struct test !\n"); */
237
m_i_struct_test__rs* m_i_struct_test__cb(CORBA_Object oe_obj,
241
CORBA_Environment *oe_env)
245
return (m_i_struct_test__rs*) (my_struct_test);
249
m_i_struct2_test__rs* m_i_struct2_test__cb(CORBA_Object oe_obj,
253
CORBA_Environment *oe_env)
255
m_i_struct2_test__rs* rs = NULL;
264
m_i_struct3_test__rs* m_i_struct3_test__cb(CORBA_Object oe_obj,
268
CORBA_Environment *oe_env)
270
m_i_struct3_test__rs* rs = NULL;
278
m_i_seq1_test__rs* m_i_seq1_test__cb(CORBA_Object oe_obj,
282
CORBA_Environment *oe_env)
284
m_i_seq1_test__rs* rs = NULL;
293
m_i_seq2_test__rs* m_i_seq2_test__cb(CORBA_Object oe_obj,
297
CORBA_Environment *oe_env)
299
m_i_seq2_test__rs* rs = NULL;
307
m_i_seq3_test__rs* m_i_seq3_test__cb(CORBA_Object oe_obj,
311
CORBA_Environment *oe_env)
313
m_i_seq3_test__rs* rs = NULL;
321
m_i_seq4_test__rs* m_i_seq4_test__cb(CORBA_Object oe_obj,
325
CORBA_Environment *oe_env)
327
m_i_seq4_test__rs* rs = NULL;
335
m_i_seq5_test__rs* m_i_seq5_test__cb(CORBA_Object oe_obj,
339
CORBA_Environment *oe_env)
341
m_i_seq5_test__rs* rs = NULL;
349
m_i_array1_test__rs* m_i_array1_test__cb(CORBA_Object oe_obj,
353
CORBA_Environment *oe_env)
356
m_i_array1_test__rs* rs = NULL;
358
for (i = 0; i < 500; i++) {
366
m_i_array2_test__rs* m_i_array2_test__cb(CORBA_Object oe_obj,
370
CORBA_Environment *oe_env)
373
m_i_array2_test__rs* rs = NULL;
375
for (i = 0; i < 2; i++)
376
for (j = 0; j < 3; j++) {
385
m_i_enum_test__rs* m_i_enum_test__cb(CORBA_Object oe_obj,
389
CORBA_Environment *oe_env)
391
m_i_enum_test__rs* rs = NULL;
399
m_i_string1_test__rs* m_i_string1_test__cb(CORBA_Object oe_obj,
403
CORBA_Environment *oe_env)
405
m_i_string1_test__rs* rs = NULL;
407
/*printf("\nString in ------> %s\n\n",b);*/
414
m_i_string2_test__rs* m_i_string2_test__cb(CORBA_Object oe_obj,
418
CORBA_Environment *oe_env)
420
m_i_string2_test__rs* rs = NULL;
428
m_i_string3_test__rs* m_i_string3_test__cb(CORBA_Object oe_obj,
432
CORBA_Environment *oe_env)
434
m_i_string3_test__rs* rs = NULL;
441
m_i_string4_test__rs* m_i_string4_test__cb(CORBA_Object oe_obj,
445
CORBA_Environment *oe_env)
450
return (m_i_string4_test__rs*) NULL;
454
m_i_wstring1_test__rs* m_i_wstring1_test__cb(CORBA_Object oe_obj,
458
CORBA_Environment *oe_env)
461
m_i_wstring1_test__rs* rs = NULL;
463
/*printf("\nString in ------> %s\n\n",b);*/
465
for(tmp = 0; tmp < 5; tmp++)
466
fprintf(stderr,"\np[%d] = %ld\n", tmp, b[tmp]);
474
m_i_pid_test__rs* m_i_pid_test__cb(CORBA_Object oe_obj,
478
CORBA_Environment *oe_env)
480
m_i_pid_test__rs* rs = NULL;
488
m_i_port_test__rs* m_i_port_test__cb(CORBA_Object oe_obj,
492
CORBA_Environment *oe_env)
494
m_i_port_test__rs* rs = NULL;
496
strcpy((*a).node,(*b).node);
500
strcpy((*c).node,(*b).node);
507
m_i_ref_test__rs* m_i_ref_test__cb(CORBA_Object oe_obj,
511
CORBA_Environment *oe_env)
514
m_i_ref_test__rs* rs = NULL;
516
strcpy((*a).node,(*b).node);
517
/*(*a).id = (*b).id;*/
519
(*a).n[0] = (*b).n[0];
520
(*a).n[1] = (*b).n[1];
521
(*a).n[2] = (*b).n[2];
524
strcpy((*c).node,(*b).node);
525
/*(*c).id = (*b).id;*/
527
(*c).n[0] = (*b).n[0];
528
(*c).n[1] = (*b).n[1];
529
(*c).n[2] = (*b).n[2];
535
m_i_term_test__rs* m_i_term_test__cb(CORBA_Object oe_obj,
539
CORBA_Environment *oe_env)
541
m_i_term_test__rs* rs = NULL;
548
m_i_typedef_test__rs* m_i_typedef_test__cb(CORBA_Object oe_obj,
554
CORBA_Environment *oe_env)
556
m_i_typedef_test__rs* rs = NULL;
559
strcpy((*e).node,(*c).node);
567
m_i_inline_sequence_test__rs* m_i_inline_sequence_test__cb(
572
CORBA_Environment *oe_env)
574
m_i_inline_sequence_test__rs* rs = NULL;
582
m_i_term_sequence_test__rs* m_i_term_sequence_test__cb(
587
CORBA_Environment *oe_env)
589
m_i_term_sequence_test__rs* rs = NULL;
598
m_i_term_struct_test__rs* m_i_term_struct_test__cb(CORBA_Object oe_obj,
602
CORBA_Environment *oe_env)
604
m_i_term_struct_test__rs* rs = NULL;