update credits
[LibreOffice.git] / stoc / test / language_binding.idl
blobe9ef5f8b99d10807d1cf2be010d4e08713bc2831
1 /*
2 * This file is part of the LibreOffice project.
4 * This Source Code Form is subject to the terms of the Mozilla Public
5 * License, v. 2.0. If a copy of the MPL was not distributed with this
6 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 * This file incorporates work covered by the following license notice:
10 * Licensed to the Apache Software Foundation (ASF) under one or more
11 * contributor license agreements. See the NOTICE file distributed
12 * with this work for additional information regarding copyright
13 * ownership. The ASF licenses this file to you under the Apache
14 * License, Version 2.0 (the "License"); you may not use this file
15 * except in compliance with the License. You may obtain a copy of
16 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
19 #ifndef _TEST_LANGUAGE_BINDING_IDL_
20 #define _TEST_LANGUAGE_BINDING_IDL_
22 #include <com/sun/star/uno/XInterface.idl>
23 #include <com/sun/star/lang/IllegalArgumentException.idl>
25 module test
28 enum TestEnum
30 TEST,
31 ONE,
32 TWO,
33 CHECK,
34 LOLA,
35 PALOO,
39 /**
40 * simple c++ types
42 struct TestSimple
44 boolean Bool;
45 char Char;
46 byte Byte;
47 short Short;
48 unsigned short UShort;
49 long Long;
50 unsigned long ULong;
51 hyper Hyper;
52 unsigned hyper UHyper;
53 float Float;
54 double Double;
55 test::TestEnum Enum;
57 /**
58 * complex c++ types
60 struct TestElement : test::TestSimple
62 string String;
63 com::sun::star::uno::XInterface Interface;
64 any Any;
66 struct TestDataElements : test::TestElement
68 sequence<test::TestElement > Sequence;
71 typedef TestDataElements TestData;
73 /**
74 * Monster test interface to test language binding calls.
76 * @author Daniel Boelzle
78 interface XLBTestBase : com::sun::star::uno::XInterface
80 /**
81 * in parameter test, tests by calls reference also (complex types)
83 void setValues( [in] boolean bBool, [in] char cChar, [in] byte nByte,
84 [in] short nShort, [in] unsigned short nUShort,
85 [in] long nLong, [in] unsigned long nULong,
86 [in] hyper nHyper, [in] unsigned hyper nUHyper,
87 [in] float fFloat, [in] double fDouble,
88 [in] test::TestEnum eEnum, [in] string aString,
89 [in] com::sun::star::uno::XInterface xInterface, [in] any aAny,
90 [in] sequence<test::TestElement > aSequence,
91 [in] test::TestData aStruct );
92 /**
93 * inout parameter test
95 test::TestData setValues2( [inout] boolean bBool, [inout] char cChar, [inout] byte nByte,
96 [inout] short nShort, [inout] unsigned short nUShort,
97 [inout] long nLong, [inout] unsigned long nULong,
98 [inout] hyper nHyper, [inout] unsigned hyper nUHyper,
99 [inout] float fFloat, [inout] double fDouble,
100 [inout] test::TestEnum eEnum, [inout] string aString,
101 [inout] com::sun::star::uno::XInterface xInterface, [inout] any aAny,
102 [inout] sequence<test::TestElement > aSequence,
103 [inout] test::TestData aStruct );
106 * out parameter test
108 test::TestData getValues( [out] boolean bBool, [out] char cChar, [out] byte nByte,
109 [out] short nShort, [out] unsigned short nUShort,
110 [out] long nLong, [out] unsigned long nULong,
111 [out] hyper nHyper, [out] unsigned hyper nUHyper,
112 [out] float fFloat, [out] double fDouble,
113 [out] test::TestEnum eEnum, [out] string aString,
114 [out] com::sun::star::uno::XInterface xInterface, [out] any aAny,
115 [out] sequence<test::TestElement > aSequence,
116 [out] test::TestData aStruct );
118 [attribute] boolean Bool;
119 [attribute] byte Byte;
120 [attribute] char Char;
121 [attribute] short Short;
122 [attribute] unsigned short UShort;
123 [attribute] long Long;
124 [attribute] unsigned long ULong;
125 [attribute] hyper Hyper;
126 [attribute] unsigned hyper UHyper;
127 [attribute] float Float;
128 [attribute] double Double;
129 [attribute] test::TestEnum Enum;
130 [attribute] string String;
131 [attribute] com::sun::star::uno::XInterface Interface;
132 [attribute] any Any;
133 [attribute] sequence<test::TestElement > Sequence;
134 [attribute] test::TestData Struct;
139 * Inherting from monster; adds raiseException().
141 * @author Daniel Boelzle
143 interface XLanguageBindingTest : test::XLBTestBase
146 * params are there only for dummy, to test if all temp out params will be released.
148 test::TestData raiseException( [out] boolean bBool, [out] char cChar, [out] byte nByte,
149 [out] short nShort, [out] unsigned short nUShort,
150 [out] long nLong, [out] unsigned long nULong,
151 [out] hyper nHyper, [out] unsigned hyper nUHyper,
152 [out] float fFloat, [out] double fDouble,
153 [out] test::TestEnum eEnum, [out] string aString,
154 [out] com::sun::star::uno::XInterface xInterface, [out] any aAny,
155 [out] sequence<test::TestElement > aSequence,
156 [out] test::TestData aStruct )
157 raises( com::sun::star::lang::IllegalArgumentException );
160 * raises runtime exception
162 [attribute] long RuntimeException;
165 }; // test
168 #endif