1/************************************************************** 2 * 3 * Licensed to the Apache Software Foundation (ASF) under one 4 * or more contributor license agreements. See the NOTICE file 5 * distributed with this work for additional information 6 * regarding copyright ownership. The ASF licenses this file 7 * to you under the Apache License, Version 2.0 (the 8 * "License"); you may not use this file except in compliance 9 * with the License. You may obtain a copy of the License at 10 * 11 * http://www.apache.org/licenses/LICENSE-2.0 12 * 13 * Unless required by applicable law or agreed to in writing, 14 * software distributed under the License is distributed on an 15 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16 * KIND, either express or implied. See the License for the 17 * specific language governing permissions and limitations 18 * under the License. 19 * 20 *************************************************************/ 21 22 23 24#include "com/sun/star/lang/ClassNotFoundException.idl" 25#include "com/sun/star/lang/IllegalAccessException.idl" 26#include "com/sun/star/uno/DeploymentException.idl" 27#include "com/sun/star/uno/Exception.idl" 28#include "com/sun/star/uno/RuntimeException.idl" 29#include "com/sun/star/uno/XInterface.idl" 30#include "com/sun/star/uno/XNamingService.idl" 31 32module test { module codemaker { module javamaker { 33 34enum Enum1 { VALUE1 = -100, VALUE2 = 100 }; 35 36enum Enum2 { VALUE0 = 0, VALUE1 = 1, VALUE2 = 2, VALUE4 = 4 }; 37 38struct Struct1 { long member1; }; 39 40struct PolyStruct<if,else> { 41 if member1; 42 long member2; 43}; 44 45interface XTest { 46 boolean test(); 47 48 [attribute, bound] long A1; 49 [attribute, bound, readonly] long A2; 50 [attribute] long A3 { 51 get raises 52 (com::sun::star::uno::Exception, 53 com::sun::star::lang::ClassNotFoundException); 54 set raises (com::sun::star::uno::RuntimeException); 55 }; 56 [attribute, readonly] long A4 { 57 get raises (com::sun::star::uno::DeploymentException); 58 }; 59}; 60 61typedef boolean Boolean; 62typedef byte Byte; 63typedef short Short; 64typedef unsigned short UnsignedShort; 65typedef long Long; 66typedef unsigned long UnsignedLong; 67typedef hyper Hyper; 68typedef unsigned hyper UnsignedHyper; 69typedef float Float; 70typedef double Double; 71typedef char Char; 72typedef string String; 73typedef type Type; 74typedef any Any; 75typedef Enum2 Enum; 76typedef Struct1 Struct; 77typedef com::sun::star::uno::XInterface XInterface; 78typedef com::sun::star::uno::XNamingService XNamingService; 79 80typedef sequence< Boolean > SequenceBoolean; 81typedef sequence< Byte > SequenceByte; 82typedef sequence< Short > SequenceShort; 83typedef sequence< UnsignedShort > SequenceUnsignedShort; 84typedef sequence< Long > SequenceLong; 85typedef sequence< UnsignedLong > SequenceUnsignedLong; 86typedef sequence< Hyper > SequenceHyper; 87typedef sequence< UnsignedHyper > SequenceUnsignedHyper; 88typedef sequence< Float > SequenceFloat; 89typedef sequence< Double > SequenceDouble; 90typedef sequence< Char > SequenceChar; 91typedef sequence< String > SequenceString; 92typedef sequence< Type > SequenceType; 93typedef sequence< Any > SequenceAny; 94typedef sequence< Enum > SequenceEnum; 95typedef sequence< Struct > SequenceStruct; 96typedef sequence< XInterface > SequenceXInterface; 97typedef sequence< XNamingService > SequenceXNamingService; 98 99struct Struct2 { 100 boolean p1; 101 byte p2; 102 short p3; 103 unsigned short p4; 104 long p5; 105 unsigned long p6; 106 hyper p7; 107 unsigned hyper p8; 108 float p9; 109 double p10; 110 char p11; 111 string p12; 112 type p13; 113 any p14; 114 Enum2 p15; 115 Struct1 p16; 116 com::sun::star::uno::XInterface p17; 117 com::sun::star::uno::XNamingService p18; 118 Boolean t1; 119 Byte t2; 120 Short t3; 121 UnsignedShort t4; 122 Long t5; 123 UnsignedLong t6; 124 Hyper t7; 125 UnsignedHyper t8; 126 Float t9; 127 Double t10; 128 Char t11; 129 String t12; 130 Type t13; 131 Any t14; 132 Enum t15; 133 Struct t16; 134 XInterface t17; 135 XNamingService t18; 136 sequence< boolean > a1; 137 sequence< byte > a2; 138 sequence< short > a3; 139 sequence< unsigned short > a4; 140 sequence< long > a5; 141 sequence< unsigned long > a6; 142 sequence< hyper > a7; 143 sequence< unsigned hyper > a8; 144 sequence< float > a9; 145 sequence< double > a10; 146 sequence< char > a11; 147 sequence< string > a12; 148 sequence< type > a13; 149 sequence< any > a14; 150 sequence< Enum2 > a15; 151 sequence< Struct1 > a16; 152 sequence< com::sun::star::uno::XInterface > a17; 153 sequence< com::sun::star::uno::XNamingService > a18; 154 sequence< sequence< boolean > > aa1; 155 sequence< sequence< byte > > aa2; 156 sequence< sequence< short > > aa3; 157 sequence< sequence< unsigned short > > aa4; 158 sequence< sequence< long > > aa5; 159 sequence< sequence< unsigned long > > aa6; 160 sequence< sequence< hyper > > aa7; 161 sequence< sequence< unsigned hyper > > aa8; 162 sequence< sequence< float > > aa9; 163 sequence< sequence< double > > aa10; 164 sequence< sequence< char > > aa11; 165 sequence< sequence< string > > aa12; 166 sequence< sequence< type > > aa13; 167 sequence< sequence< any > > aa14; 168 sequence< sequence< Enum2 > > aa15; 169 sequence< sequence< Struct1 > > aa16; 170 sequence< sequence< com::sun::star::uno::XInterface > > aa17; 171 sequence< sequence< com::sun::star::uno::XNamingService > > aa18; 172 sequence< SequenceBoolean > at1; 173 sequence< SequenceByte > at2; 174 sequence< SequenceShort > at3; 175 sequence< SequenceUnsignedShort > at4; 176 sequence< SequenceLong > at5; 177 sequence< SequenceUnsignedLong > at6; 178 sequence< SequenceHyper > at7; 179 sequence< SequenceUnsignedHyper > at8; 180 sequence< SequenceFloat > at9; 181 sequence< SequenceDouble > at10; 182 sequence< SequenceChar > at11; 183 sequence< SequenceString > at12; 184 sequence< SequenceType > at13; 185 sequence< SequenceAny > at14; 186 sequence< SequenceEnum > at15; 187 sequence< SequenceStruct > at16; 188 sequence< SequenceXInterface > at17; 189 sequence< SequenceXNamingService > at18; 190}; 191 192service S1: XTest { 193 create1(); 194 195 create2([in] any... create2) 196 raises (com::sun::star::uno::RuntimeException, 197 com::sun::star::lang::ClassNotFoundException, 198 com::sun::star::uno::Exception, 199 com::sun::star::lang::IllegalAccessException, 200 com::sun::star::uno::DeploymentException); 201 202 create3([in] sequence<any> S1) 203 raises (com::sun::star::uno::RuntimeException, 204 com::sun::star::lang::ClassNotFoundException, 205 com::sun::star::lang::IllegalAccessException, 206 com::sun::star::uno::DeploymentException); 207 208 create4([in] long javamaker, [in] long S1, [in] long create4); 209 210 create5( 211 [in] boolean p1, 212 [in] byte p2, 213 [in] short p3, 214 [in] unsigned short p4, 215 [in] long p5, 216 [in] unsigned long p6, 217 [in] hyper p7, 218 [in] unsigned hyper p8, 219 [in] float p9, 220 [in] double p10, 221 [in] char p11, 222 [in] string p12, 223 [in] type p13, 224 [in] any p14, 225 [in] Enum2 p15, 226 [in] Struct1 p16, 227 [in] com::sun::star::uno::XInterface p17, 228 [in] com::sun::star::uno::XNamingService p18, 229 [in] Boolean t1, 230 [in] Byte t2, 231 [in] Short t3, 232 [in] UnsignedShort t4, 233 [in] Long t5, 234 [in] UnsignedLong t6, 235 [in] Hyper t7, 236 [in] UnsignedHyper t8, 237 [in] Float t9, 238 [in] Double t10, 239 [in] Char t11, 240 [in] String t12, 241 [in] Type t13, 242 [in] Any t14, 243 [in] Enum t15, 244 [in] Struct t16, 245 [in] XInterface t17, 246 [in] XNamingService t18, 247 [in] sequence< boolean > a1, 248 [in] sequence< byte > a2, 249 [in] sequence< short > a3, 250 [in] sequence< unsigned short > a4, 251 [in] sequence< long > a5, 252 [in] sequence< unsigned long > a6, 253 [in] sequence< hyper > a7, 254 [in] sequence< unsigned hyper > a8, 255 [in] sequence< float > a9, 256 [in] sequence< double > a10, 257 [in] sequence< char > a11, 258 [in] sequence< string > a12, 259 [in] sequence< type > a13, 260 [in] sequence< any > a14, 261 [in] sequence< Enum2 > a15, 262 [in] sequence< Struct1 > a16, 263 [in] sequence< com::sun::star::uno::XInterface > a17, 264 [in] sequence< com::sun::star::uno::XNamingService > a18, 265 [in] sequence< sequence< boolean > > aa1, 266 [in] sequence< sequence< byte > > aa2, 267 [in] sequence< sequence< short > > aa3, 268 [in] sequence< sequence< unsigned short > > aa4, 269 [in] sequence< sequence< long > > aa5, 270 [in] sequence< sequence< unsigned long > > aa6, 271 [in] sequence< sequence< hyper > > aa7, 272 [in] sequence< sequence< unsigned hyper > > aa8, 273 [in] sequence< sequence< float > > aa9, 274 [in] sequence< sequence< double > > aa10, 275 [in] sequence< sequence< char > > aa11, 276 [in] sequence< sequence< string > > aa12, 277 [in] sequence< sequence< type > > aa13, 278 [in] sequence< sequence< any > > aa14, 279 [in] sequence< sequence< Enum2 > > aa15, 280 [in] sequence< sequence< Struct1 > > aa16, 281 [in] sequence< sequence< com::sun::star::uno::XInterface > > aa17, 282 [in] sequence< sequence< com::sun::star::uno::XNamingService > > aa18, 283 [in] sequence< SequenceBoolean > at1, 284 [in] sequence< SequenceByte > at2, 285 [in] sequence< SequenceShort > at3, 286 [in] sequence< SequenceUnsignedShort > at4, 287 [in] sequence< SequenceLong > at5, 288 [in] sequence< SequenceUnsignedLong > at6, 289 [in] sequence< SequenceHyper > at7, 290 [in] sequence< SequenceUnsignedHyper > at8, 291 [in] sequence< SequenceFloat > at9, 292 [in] sequence< SequenceDouble > at10, 293 [in] sequence< SequenceChar > at11, 294 [in] sequence< SequenceString > at12, 295 [in] sequence< SequenceType > at13, 296 [in] sequence< SequenceAny > at14, 297 [in] sequence< SequenceEnum > at15, 298 [in] sequence< SequenceStruct > at16, 299 [in] sequence< SequenceXInterface > at17, 300 [in] sequence< SequenceXNamingService > at18); 301}; 302 303service S2: XTest; 304 305service S3 { interface XTest; }; 306 307module services { 308 309service abstract: com::sun::star::uno::XInterface { 310 abstract([in] long abstract); }; 311service assert: com::sun::star::uno::XInterface { assert([in] long assert); }; 312//TODO: boolean 313service break: com::sun::star::uno::XInterface { break([in] long break); }; 314//TODO: byte 315//TODO: case 316service catch: com::sun::star::uno::XInterface { catch([in] long catch); }; 317//TODO: char 318service class: com::sun::star::uno::XInterface { class([in] long class); }; 319//TODO: const 320service continue: com::sun::star::uno::XInterface { 321 continue([in] long continue); }; 322//TODO: default 323service do: com::sun::star::uno::XInterface { do([in] long do); }; 324//TODO: double 325service else: com::sun::star::uno::XInterface { else([in] long else); }; 326//TODO: enum 327service extends: com::sun::star::uno::XInterface { 328 extends([in] long extends); }; 329service final: com::sun::star::uno::XInterface { final([in] long final); }; 330service finally: com::sun::star::uno::XInterface { 331 finally([in] long finally); }; 332//TODO: float 333service for: com::sun::star::uno::XInterface { for([in] long for); }; 334service goto: com::sun::star::uno::XInterface { goto([in] long goto); }; 335service if: com::sun::star::uno::XInterface { if([in] long if); }; 336service implements: com::sun::star::uno::XInterface { 337 implements([in] long implements); }; 338service import: com::sun::star::uno::XInterface { import([in] long import); }; 339service instanceof: com::sun::star::uno::XInterface { 340 instanceof([in] long instanceof); }; 341service int: com::sun::star::uno::XInterface { int([in] long int); }; 342//TODO: interface 343//TODO: long 344service native: com::sun::star::uno::XInterface { native([in] long native); }; 345service new: com::sun::star::uno::XInterface { new([in] long new); }; 346service package: com::sun::star::uno::XInterface { 347 package([in] long package); }; 348service private: com::sun::star::uno::XInterface { 349 private([in] long private); }; 350service protected: com::sun::star::uno::XInterface { 351 protected([in] long protected); }; 352service public: com::sun::star::uno::XInterface { public([in] long public); }; 353service return: com::sun::star::uno::XInterface { return([in] long return); }; 354//TODO: short 355service static: com::sun::star::uno::XInterface { static([in] long static); }; 356service strictfp: com::sun::star::uno::XInterface { 357 strictfp([in] long strictfp); }; 358service super: com::sun::star::uno::XInterface { super([in] long super); }; 359//TODO: switch 360service synchronized: com::sun::star::uno::XInterface { 361 synchronized([in] long synchronized); }; 362service this: com::sun::star::uno::XInterface { this([in] long this); }; 363service throw: com::sun::star::uno::XInterface { throw([in] long throw); }; 364service throws: com::sun::star::uno::XInterface { throws([in] long throws); }; 365//TODO: transient 366service try: com::sun::star::uno::XInterface { try([in] long try); }; 367//TODO: void 368service volatile: com::sun::star::uno::XInterface { 369 volatile([in] long volatile); }; 370service while: com::sun::star::uno::XInterface { while([in] long while); }; 371 372}; 373 374singleton S4: XTest; 375 376singleton S5 { service S2; }; 377 378singleton abstract: com::sun::star::uno::XNamingService; 379singleton assert: com::sun::star::uno::XNamingService; 380//TODO: singleton boolean: com::sun::star::uno::XNamingService; 381singleton break: com::sun::star::uno::XNamingService; 382//TODO: singleton byte: com::sun::star::uno::XNamingService; 383//TODO: singleton case: com::sun::star::uno::XNamingService; 384singleton catch: com::sun::star::uno::XNamingService; 385//TODO: singleton char: com::sun::star::uno::XNamingService; 386singleton class: com::sun::star::uno::XNamingService; 387//TODO: singleton const: com::sun::star::uno::XNamingService; 388singleton continue: com::sun::star::uno::XNamingService; 389//TODO: singleton default: com::sun::star::uno::XNamingService; 390singleton do: com::sun::star::uno::XNamingService; 391//TODO: singleton double: com::sun::star::uno::XNamingService; 392singleton else: com::sun::star::uno::XNamingService; 393//TODO: singleton enum: com::sun::star::uno::XNamingService; 394singleton extends: com::sun::star::uno::XNamingService; 395singleton final: com::sun::star::uno::XNamingService; 396singleton finally: com::sun::star::uno::XNamingService; 397//TODO: singleton float: com::sun::star::uno::XNamingService; 398singleton for: com::sun::star::uno::XNamingService; 399singleton goto: com::sun::star::uno::XNamingService; 400singleton if: com::sun::star::uno::XNamingService; 401singleton implements: com::sun::star::uno::XNamingService; 402singleton import: com::sun::star::uno::XNamingService; 403singleton instanceof: com::sun::star::uno::XNamingService; 404singleton int: com::sun::star::uno::XNamingService; 405//TODO: singleton interface: com::sun::star::uno::XNamingService; 406//TODO: singleton long: com::sun::star::uno::XNamingService; 407singleton native: com::sun::star::uno::XNamingService; 408singleton new: com::sun::star::uno::XNamingService; 409singleton package: com::sun::star::uno::XNamingService; 410singleton private: com::sun::star::uno::XNamingService; 411singleton protected: com::sun::star::uno::XNamingService; 412singleton public: com::sun::star::uno::XNamingService; 413singleton return: com::sun::star::uno::XNamingService; 414//TODO: singleton short: com::sun::star::uno::XNamingService; 415singleton static: com::sun::star::uno::XNamingService; 416singleton strictfp: com::sun::star::uno::XNamingService; 417singleton super: com::sun::star::uno::XNamingService; 418//TODO: singleton switch: com::sun::star::uno::XNamingService; 419singleton synchronized: com::sun::star::uno::XNamingService; 420singleton this: com::sun::star::uno::XNamingService; 421singleton throw: com::sun::star::uno::XNamingService; 422singleton throws: com::sun::star::uno::XNamingService; 423//TODO: singleton transient: com::sun::star::uno::XNamingService; 424singleton try: com::sun::star::uno::XNamingService; 425//TODO: singleton void: com::sun::star::uno::XNamingService; 426singleton volatile: com::sun::star::uno::XNamingService; 427singleton while: com::sun::star::uno::XNamingService; 428 429}; }; }; 430