Harald Welte | ac35980 | 2017-04-12 12:13:44 +0200 | [diff] [blame] | 1 | /****************************************************************************** |
| 2 | * Copyright (c) 2005, 2014 Ericsson AB |
| 3 | * All rights reserved. This program and the accompanying materials |
| 4 | * are made available under the terms of the Eclipse Public License v1.0 |
| 5 | * which accompanies this distribution, and is available at |
| 6 | * http://www.eclipse.org/legal/epl-v10.html |
| 7 | * |
| 8 | * Contributors: |
| 9 | * Peter Dimitrov- initial implementation and initial documentation |
| 10 | * Adam Delic |
| 11 | * Eduard Czimbalmos |
| 12 | * Endre Kulcsar |
| 13 | * Gabor Bettesch |
| 14 | * Gabor Szalai |
| 15 | * Tamas Buti |
| 16 | * Zoltan Medve |
| 17 | ******************************************************************************/ |
| 18 | // |
| 19 | // File: SCTPasp_Types.ttcn |
| 20 | // Description: SCTP ASP definition file |
| 21 | // Rev: R11A |
| 22 | // Prodnr: CNL 113 469 |
| 23 | // |
| 24 | |
| 25 | |
| 26 | module SCTPasp_Types |
| 27 | { |
| 28 | |
| 29 | //========================================================================= |
| 30 | // Data Types |
| 31 | //========================================================================= |
| 32 | |
| 33 | type octetstring PDU_SCTP; |
| 34 | |
| 35 | type record ASP_SCTP |
| 36 | { |
| 37 | integer client_id optional, |
| 38 | integer sinfo_stream, |
| 39 | integer sinfo_ppid, |
| 40 | PDU_SCTP data |
| 41 | } |
| 42 | |
| 43 | |
| 44 | type record ASP_SCTP_Connect |
| 45 | { |
| 46 | charstring peer_hostname optional, |
| 47 | integer peer_portnumber (1..65535) optional |
| 48 | } |
| 49 | |
| 50 | |
| 51 | type record ASP_SCTP_ConnectFrom |
| 52 | { |
| 53 | charstring local_hostname optional, |
| 54 | integer local_portnumber (1..65535), |
| 55 | charstring peer_hostname optional, |
| 56 | integer peer_portnumber (1..65535) optional |
| 57 | } |
| 58 | |
| 59 | |
| 60 | type record ASP_SCTP_Listen |
| 61 | { |
| 62 | charstring local_hostname optional, |
| 63 | integer local_portnumber (1..65535) |
| 64 | } |
| 65 | |
| 66 | |
| 67 | type record SCTP_INIT |
| 68 | { |
| 69 | integer sinit_num_ostreams, |
| 70 | integer sinit_max_instreams, |
| 71 | integer sinit_max_attempts, |
| 72 | integer sinit_max_init_timeo |
| 73 | } |
| 74 | |
| 75 | type record SCTP_EVENTS |
| 76 | { |
| 77 | boolean sctp_data_io_event, |
| 78 | boolean sctp_association_event, |
| 79 | boolean sctp_address_event, |
| 80 | boolean sctp_send_failure_event, |
| 81 | boolean sctp_peer_error_event, |
| 82 | boolean sctp_shutdown_event, |
| 83 | boolean sctp_partial_delivery_event, |
| 84 | boolean sctp_adaption_layer_event |
| 85 | } |
| 86 | |
| 87 | type record SO_LINGER |
| 88 | { |
| 89 | integer l_onoff, |
| 90 | integer l_linger |
| 91 | } |
| 92 | |
| 93 | type record SCTP_RTOINFO |
| 94 | { |
| 95 | integer client_id, |
| 96 | integer srto_initial, |
| 97 | integer srto_max, |
| 98 | integer srto_min |
| 99 | } |
| 100 | |
| 101 | type union ASP_SCTP_SetSocketOptions |
| 102 | { |
| 103 | SCTP_INIT Sctp_init, |
| 104 | SCTP_EVENTS Sctp_events, |
| 105 | SO_LINGER So_linger, |
| 106 | SCTP_RTOINFO Sctp_rtoinfo |
| 107 | } |
| 108 | |
| 109 | |
| 110 | type record ASP_SCTP_Close |
| 111 | { |
| 112 | integer client_id optional |
| 113 | } |
| 114 | |
| 115 | |
| 116 | type enumerated SAC_STATE |
| 117 | { |
| 118 | SCTP_COMM_UP, SCTP_COMM_LOST, SCTP_RESTART, |
| 119 | SCTP_SHUTDOWN_COMP, SCTP_CANT_STR_ASSOC, SCTP_UNKNOWN_SAC_STATE |
| 120 | } |
| 121 | |
| 122 | type record ASP_SCTP_ASSOC_CHANGE |
| 123 | { |
| 124 | integer client_id, |
| 125 | SAC_STATE sac_state |
| 126 | } |
| 127 | |
| 128 | |
| 129 | type enumerated SPC_STATE |
| 130 | { |
| 131 | SCTP_ADDR_AVAILABLE, SCTP_ADDR_UNREACHABLE, SCTP_ADDR_REMOVED, |
| 132 | SCTP_ADDR_ADDED, SCTP_ADDR_MADE_PRIM, SCTP_ADDR_CONFIRMED, SCTP_UNKNOWN_SPC_STATE |
| 133 | } |
| 134 | |
| 135 | type record ASP_SCTP_PEER_ADDR_CHANGE |
| 136 | { |
| 137 | integer client_id, |
| 138 | SPC_STATE spc_state |
| 139 | } |
| 140 | |
| 141 | |
| 142 | type record ASP_SCTP_SEND_FAILED |
| 143 | { |
| 144 | integer client_id |
| 145 | } |
| 146 | |
| 147 | |
| 148 | type record ASP_SCTP_REMOTE_ERROR |
| 149 | { |
| 150 | integer client_id |
| 151 | } |
| 152 | |
| 153 | |
| 154 | type record ASP_SCTP_SHUTDOWN_EVENT |
| 155 | { |
| 156 | integer client_id |
| 157 | } |
| 158 | |
| 159 | |
| 160 | type record ASP_SCTP_PARTIAL_DELIVERY_EVENT |
| 161 | { |
| 162 | integer client_id |
| 163 | } |
| 164 | |
| 165 | |
| 166 | type record ASP_SCTP_ADAPTION_INDICATION |
| 167 | { |
| 168 | integer client_id |
| 169 | } |
| 170 | |
| 171 | |
| 172 | type record ASP_SCTP_Connected |
| 173 | { |
| 174 | integer client_id, |
| 175 | charstring local_hostname, |
| 176 | integer local_portnumber (1..65535), |
| 177 | charstring peer_hostname, |
| 178 | integer peer_portnumber (1..65535) |
| 179 | } |
| 180 | |
| 181 | |
| 182 | type record ASP_SCTP_SENDMSG_ERROR |
| 183 | { |
| 184 | integer client_id optional, |
| 185 | integer sinfo_stream, |
| 186 | integer sinfo_ppid, |
| 187 | PDU_SCTP data |
| 188 | } |
| 189 | |
| 190 | type record ASP_SCTP_RESULT |
| 191 | { |
| 192 | integer client_id optional, |
| 193 | boolean error_status, |
| 194 | charstring error_message optional |
| 195 | } |
| 196 | |
| 197 | }//end of module |
| 198 | with { |
| 199 | extension "version R11A" |
| 200 | } |
| 201 | |