blob: 955cdc9a749ee89bffbaf1e36ec32393f8156040 [file] [log] [blame]
David Reissea2cba82009-03-30 21:35:00 +00001/*
2 * Licensed to the Apache Software Foundation (ASF) under one
3 * or more contributor license agreements. See the NOTICE file
4 * distributed with this work for additional information
5 * regarding copyright ownership. The ASF licenses this file
6 * to you under the Apache License, Version 2.0 (the
7 * "License"); you may not use this file except in compliance
8 * with the License. You may obtain a copy of the License at
9 *
10 * http://www.apache.org/licenses/LICENSE-2.0
11 *
12 * Unless required by applicable law or agreed to in writing,
13 * software distributed under the License is distributed on an
14 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15 * KIND, either express or implied. See the License for the
16 * specific language governing permissions and limitations
17 * under the License.
18 */
19
Mark Sleee129a2d2007-02-21 05:17:48 +000020
Kevin Clarka7e7c042008-06-18 00:52:05 +000021namespace rb TestNamespace
Kevin Clarkd5c98ee2008-06-18 00:51:45 +000022
Mark Sleee129a2d2007-02-21 05:17:48 +000023struct Goodbyez {
24 1: i32 val = 325;
Mark Slee9e288d42007-01-24 23:42:12 +000025}
26
Kevin Clark4bd89162008-07-08 00:47:49 +000027struct BoolPasser {
28 1: bool value = 1
29}
30
Mark Sleee129a2d2007-02-21 05:17:48 +000031struct Hello {
32 1: i32 simple = 53,
33 2: map<i32,i32> complex = {23:532, 6243:632, 2355:532},
34 3: map<i32, map<i32,i32>> complexer,
35 4: string words = "words",
36 5: Goodbyez thinz = {'val' : 36632}
37}
38
39const map<i32,map<i32,i32>> CMAP = { 235: {235:235}, 53:{53:53} }
40const i32 CINT = 325;
41const Hello WHOA = {'simple' : 532}
42
Mark Slee9e288d42007-01-24 23:42:12 +000043exception Goodbye {
44 1: i32 simple,
45 2: map<i32,i32> complex,
David Reiss0c90f6f2008-02-06 22:18:40 +000046 3: map<i32, map<i32,i32>> complexer,
Mark Slee9e288d42007-01-24 23:42:12 +000047}
48
Jens Geyer0b1eb6b2022-06-05 11:12:49 +020049struct Thinger {
50 1: i32 dummy
51}
52
Mark Slee9e288d42007-01-24 23:42:12 +000053service SmallService {
Jens Geyer85d81622019-10-10 01:33:30 +020054 Thinger testThinger(1:Thinger bootz),
Mark Sleee129a2d2007-02-21 05:17:48 +000055 Hello testMe(1:i32 hello=64, 2: Hello wonk) throws (1: Goodbye g),
Mark Slee9e288d42007-01-24 23:42:12 +000056 void testVoid() throws (1: Goodbye g),
57 i32 testI32(1:i32 boo)
58}