blob: d0821c7ffb03aff628e62b495514fc8fb4657050 [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
Jens Geyer85d81622019-10-10 01:33:30 +020027senum Thinger {
28 "ASDFKJ",
29 "r32)*F#@",
30 "ASDFLJASDF"
31}
32
Kevin Clark4bd89162008-07-08 00:47:49 +000033struct BoolPasser {
34 1: bool value = 1
35}
36
Mark Sleee129a2d2007-02-21 05:17:48 +000037struct Hello {
38 1: i32 simple = 53,
39 2: map<i32,i32> complex = {23:532, 6243:632, 2355:532},
40 3: map<i32, map<i32,i32>> complexer,
41 4: string words = "words",
42 5: Goodbyez thinz = {'val' : 36632}
43}
44
45const map<i32,map<i32,i32>> CMAP = { 235: {235:235}, 53:{53:53} }
46const i32 CINT = 325;
47const Hello WHOA = {'simple' : 532}
48
Mark Slee9e288d42007-01-24 23:42:12 +000049exception Goodbye {
50 1: i32 simple,
51 2: map<i32,i32> complex,
David Reiss0c90f6f2008-02-06 22:18:40 +000052 3: map<i32, map<i32,i32>> complexer,
Mark Slee9e288d42007-01-24 23:42:12 +000053}
54
55service SmallService {
Jens Geyer85d81622019-10-10 01:33:30 +020056 Thinger testThinger(1:Thinger bootz),
Mark Sleee129a2d2007-02-21 05:17:48 +000057 Hello testMe(1:i32 hello=64, 2: Hello wonk) throws (1: Goodbye g),
Mark Slee9e288d42007-01-24 23:42:12 +000058 void testVoid() throws (1: Goodbye g),
59 i32 testI32(1:i32 boo)
60}