Matteo Scandolo | a6a3aee | 2019-11-26 13:30:14 -0700 | [diff] [blame] | 1 | // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. |
| 2 | // source: api/bbsim/bbsim.proto |
| 3 | |
| 4 | /* |
| 5 | Package bbsim is a reverse proxy. |
| 6 | |
| 7 | It translates gRPC into RESTful JSON APIs. |
| 8 | */ |
| 9 | package bbsim |
| 10 | |
| 11 | import ( |
| 12 | "context" |
| 13 | "io" |
| 14 | "net/http" |
| 15 | |
Pragya Arya | bd731ec | 2020-02-11 16:38:17 +0530 | [diff] [blame^] | 16 | "github.com/golang/protobuf/descriptor" |
Matteo Scandolo | a6a3aee | 2019-11-26 13:30:14 -0700 | [diff] [blame] | 17 | "github.com/golang/protobuf/proto" |
| 18 | "github.com/grpc-ecosystem/grpc-gateway/runtime" |
| 19 | "github.com/grpc-ecosystem/grpc-gateway/utilities" |
| 20 | "google.golang.org/grpc" |
| 21 | "google.golang.org/grpc/codes" |
| 22 | "google.golang.org/grpc/grpclog" |
| 23 | "google.golang.org/grpc/status" |
| 24 | ) |
| 25 | |
Pragya Arya | bd731ec | 2020-02-11 16:38:17 +0530 | [diff] [blame^] | 26 | // Suppress "imported and not used" errors |
Matteo Scandolo | a6a3aee | 2019-11-26 13:30:14 -0700 | [diff] [blame] | 27 | var _ codes.Code |
| 28 | var _ io.Reader |
| 29 | var _ status.Status |
| 30 | var _ = runtime.String |
| 31 | var _ = utilities.NewDoubleArray |
Pragya Arya | bd731ec | 2020-02-11 16:38:17 +0530 | [diff] [blame^] | 32 | var _ = descriptor.ForMessage |
Matteo Scandolo | a6a3aee | 2019-11-26 13:30:14 -0700 | [diff] [blame] | 33 | |
| 34 | func request_BBSim_Version_0(ctx context.Context, marshaler runtime.Marshaler, client BBSimClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 35 | var protoReq Empty |
| 36 | var metadata runtime.ServerMetadata |
| 37 | |
| 38 | msg, err := client.Version(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) |
| 39 | return msg, metadata, err |
| 40 | |
| 41 | } |
| 42 | |
Pragya Arya | 1cbefa4 | 2020-01-13 12:15:29 +0530 | [diff] [blame] | 43 | func local_request_BBSim_Version_0(ctx context.Context, marshaler runtime.Marshaler, server BBSimServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 44 | var protoReq Empty |
| 45 | var metadata runtime.ServerMetadata |
| 46 | |
| 47 | msg, err := server.Version(ctx, &protoReq) |
| 48 | return msg, metadata, err |
| 49 | |
| 50 | } |
| 51 | |
Matteo Scandolo | a6a3aee | 2019-11-26 13:30:14 -0700 | [diff] [blame] | 52 | func request_BBSim_GetOlt_0(ctx context.Context, marshaler runtime.Marshaler, client BBSimClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 53 | var protoReq Empty |
| 54 | var metadata runtime.ServerMetadata |
| 55 | |
| 56 | msg, err := client.GetOlt(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) |
| 57 | return msg, metadata, err |
| 58 | |
| 59 | } |
| 60 | |
Pragya Arya | 1cbefa4 | 2020-01-13 12:15:29 +0530 | [diff] [blame] | 61 | func local_request_BBSim_GetOlt_0(ctx context.Context, marshaler runtime.Marshaler, server BBSimServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 62 | var protoReq Empty |
| 63 | var metadata runtime.ServerMetadata |
| 64 | |
| 65 | msg, err := server.GetOlt(ctx, &protoReq) |
| 66 | return msg, metadata, err |
| 67 | |
| 68 | } |
| 69 | |
Matteo Scandolo | a6a3aee | 2019-11-26 13:30:14 -0700 | [diff] [blame] | 70 | func request_BBSim_GetOlt_1(ctx context.Context, marshaler runtime.Marshaler, client BBSimClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 71 | var protoReq Empty |
| 72 | var metadata runtime.ServerMetadata |
| 73 | |
| 74 | msg, err := client.GetOlt(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) |
| 75 | return msg, metadata, err |
| 76 | |
| 77 | } |
| 78 | |
Pragya Arya | 1cbefa4 | 2020-01-13 12:15:29 +0530 | [diff] [blame] | 79 | func local_request_BBSim_GetOlt_1(ctx context.Context, marshaler runtime.Marshaler, server BBSimServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 80 | var protoReq Empty |
| 81 | var metadata runtime.ServerMetadata |
| 82 | |
| 83 | msg, err := server.GetOlt(ctx, &protoReq) |
| 84 | return msg, metadata, err |
| 85 | |
| 86 | } |
| 87 | |
Matteo Scandolo | a6a3aee | 2019-11-26 13:30:14 -0700 | [diff] [blame] | 88 | func request_BBSim_GetONU_0(ctx context.Context, marshaler runtime.Marshaler, client BBSimClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 89 | var protoReq ONURequest |
| 90 | var metadata runtime.ServerMetadata |
| 91 | |
| 92 | var ( |
| 93 | val string |
| 94 | ok bool |
| 95 | err error |
| 96 | _ = err |
| 97 | ) |
| 98 | |
| 99 | val, ok = pathParams["SerialNumber"] |
| 100 | if !ok { |
| 101 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "SerialNumber") |
| 102 | } |
| 103 | |
| 104 | protoReq.SerialNumber, err = runtime.String(val) |
| 105 | |
| 106 | if err != nil { |
| 107 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "SerialNumber", err) |
| 108 | } |
| 109 | |
| 110 | msg, err := client.GetONU(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) |
| 111 | return msg, metadata, err |
| 112 | |
| 113 | } |
| 114 | |
Pragya Arya | 1cbefa4 | 2020-01-13 12:15:29 +0530 | [diff] [blame] | 115 | func local_request_BBSim_GetONU_0(ctx context.Context, marshaler runtime.Marshaler, server BBSimServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 116 | var protoReq ONURequest |
| 117 | var metadata runtime.ServerMetadata |
| 118 | |
| 119 | var ( |
| 120 | val string |
| 121 | ok bool |
| 122 | err error |
| 123 | _ = err |
| 124 | ) |
| 125 | |
| 126 | val, ok = pathParams["SerialNumber"] |
| 127 | if !ok { |
| 128 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "SerialNumber") |
| 129 | } |
| 130 | |
| 131 | protoReq.SerialNumber, err = runtime.String(val) |
| 132 | |
| 133 | if err != nil { |
| 134 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "SerialNumber", err) |
| 135 | } |
| 136 | |
| 137 | msg, err := server.GetONU(ctx, &protoReq) |
| 138 | return msg, metadata, err |
| 139 | |
| 140 | } |
| 141 | |
Pragya Arya | bd731ec | 2020-02-11 16:38:17 +0530 | [diff] [blame^] | 142 | func request_BBSim_GetONUs_0(ctx context.Context, marshaler runtime.Marshaler, client BBSimClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 143 | var protoReq Empty |
| 144 | var metadata runtime.ServerMetadata |
| 145 | |
| 146 | msg, err := client.GetONUs(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) |
| 147 | return msg, metadata, err |
| 148 | |
| 149 | } |
| 150 | |
| 151 | func local_request_BBSim_GetONUs_0(ctx context.Context, marshaler runtime.Marshaler, server BBSimServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 152 | var protoReq Empty |
| 153 | var metadata runtime.ServerMetadata |
| 154 | |
| 155 | msg, err := server.GetONUs(ctx, &protoReq) |
| 156 | return msg, metadata, err |
| 157 | |
| 158 | } |
| 159 | |
Pragya Arya | 1cbefa4 | 2020-01-13 12:15:29 +0530 | [diff] [blame] | 160 | func request_BBSim_ShutdownONU_0(ctx context.Context, marshaler runtime.Marshaler, client BBSimClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 161 | var protoReq ONURequest |
| 162 | var metadata runtime.ServerMetadata |
| 163 | |
| 164 | var ( |
| 165 | val string |
| 166 | ok bool |
| 167 | err error |
| 168 | _ = err |
| 169 | ) |
| 170 | |
| 171 | val, ok = pathParams["SerialNumber"] |
| 172 | if !ok { |
| 173 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "SerialNumber") |
| 174 | } |
| 175 | |
| 176 | protoReq.SerialNumber, err = runtime.String(val) |
| 177 | |
| 178 | if err != nil { |
| 179 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "SerialNumber", err) |
| 180 | } |
| 181 | |
| 182 | msg, err := client.ShutdownONU(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) |
| 183 | return msg, metadata, err |
| 184 | |
| 185 | } |
| 186 | |
| 187 | func local_request_BBSim_ShutdownONU_0(ctx context.Context, marshaler runtime.Marshaler, server BBSimServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 188 | var protoReq ONURequest |
| 189 | var metadata runtime.ServerMetadata |
| 190 | |
| 191 | var ( |
| 192 | val string |
| 193 | ok bool |
| 194 | err error |
| 195 | _ = err |
| 196 | ) |
| 197 | |
| 198 | val, ok = pathParams["SerialNumber"] |
| 199 | if !ok { |
| 200 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "SerialNumber") |
| 201 | } |
| 202 | |
| 203 | protoReq.SerialNumber, err = runtime.String(val) |
| 204 | |
| 205 | if err != nil { |
| 206 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "SerialNumber", err) |
| 207 | } |
| 208 | |
| 209 | msg, err := server.ShutdownONU(ctx, &protoReq) |
| 210 | return msg, metadata, err |
| 211 | |
| 212 | } |
| 213 | |
Pragya Arya | bd731ec | 2020-02-11 16:38:17 +0530 | [diff] [blame^] | 214 | func request_BBSim_ShutdownAllONUs_0(ctx context.Context, marshaler runtime.Marshaler, client BBSimClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 215 | var protoReq Empty |
| 216 | var metadata runtime.ServerMetadata |
| 217 | |
| 218 | msg, err := client.ShutdownAllONUs(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) |
| 219 | return msg, metadata, err |
| 220 | |
| 221 | } |
| 222 | |
| 223 | func local_request_BBSim_ShutdownAllONUs_0(ctx context.Context, marshaler runtime.Marshaler, server BBSimServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 224 | var protoReq Empty |
| 225 | var metadata runtime.ServerMetadata |
| 226 | |
| 227 | msg, err := server.ShutdownAllONUs(ctx, &protoReq) |
| 228 | return msg, metadata, err |
| 229 | |
| 230 | } |
| 231 | |
| 232 | func request_BBSim_ShutdownONUsOnPON_0(ctx context.Context, marshaler runtime.Marshaler, client BBSimClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 233 | var protoReq PONRequest |
| 234 | var metadata runtime.ServerMetadata |
| 235 | |
| 236 | var ( |
| 237 | val string |
| 238 | ok bool |
| 239 | err error |
| 240 | _ = err |
| 241 | ) |
| 242 | |
| 243 | val, ok = pathParams["PonPortId"] |
| 244 | if !ok { |
| 245 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "PonPortId") |
| 246 | } |
| 247 | |
| 248 | protoReq.PonPortId, err = runtime.Uint32(val) |
| 249 | |
| 250 | if err != nil { |
| 251 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "PonPortId", err) |
| 252 | } |
| 253 | |
| 254 | msg, err := client.ShutdownONUsOnPON(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) |
| 255 | return msg, metadata, err |
| 256 | |
| 257 | } |
| 258 | |
| 259 | func local_request_BBSim_ShutdownONUsOnPON_0(ctx context.Context, marshaler runtime.Marshaler, server BBSimServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 260 | var protoReq PONRequest |
| 261 | var metadata runtime.ServerMetadata |
| 262 | |
| 263 | var ( |
| 264 | val string |
| 265 | ok bool |
| 266 | err error |
| 267 | _ = err |
| 268 | ) |
| 269 | |
| 270 | val, ok = pathParams["PonPortId"] |
| 271 | if !ok { |
| 272 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "PonPortId") |
| 273 | } |
| 274 | |
| 275 | protoReq.PonPortId, err = runtime.Uint32(val) |
| 276 | |
| 277 | if err != nil { |
| 278 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "PonPortId", err) |
| 279 | } |
| 280 | |
| 281 | msg, err := server.ShutdownONUsOnPON(ctx, &protoReq) |
| 282 | return msg, metadata, err |
| 283 | |
| 284 | } |
| 285 | |
Pragya Arya | 1cbefa4 | 2020-01-13 12:15:29 +0530 | [diff] [blame] | 286 | func request_BBSim_PoweronONU_0(ctx context.Context, marshaler runtime.Marshaler, client BBSimClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 287 | var protoReq ONURequest |
| 288 | var metadata runtime.ServerMetadata |
| 289 | |
| 290 | var ( |
| 291 | val string |
| 292 | ok bool |
| 293 | err error |
| 294 | _ = err |
| 295 | ) |
| 296 | |
| 297 | val, ok = pathParams["SerialNumber"] |
| 298 | if !ok { |
| 299 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "SerialNumber") |
| 300 | } |
| 301 | |
| 302 | protoReq.SerialNumber, err = runtime.String(val) |
| 303 | |
| 304 | if err != nil { |
| 305 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "SerialNumber", err) |
| 306 | } |
| 307 | |
| 308 | msg, err := client.PoweronONU(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) |
| 309 | return msg, metadata, err |
| 310 | |
| 311 | } |
| 312 | |
| 313 | func local_request_BBSim_PoweronONU_0(ctx context.Context, marshaler runtime.Marshaler, server BBSimServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 314 | var protoReq ONURequest |
| 315 | var metadata runtime.ServerMetadata |
| 316 | |
| 317 | var ( |
| 318 | val string |
| 319 | ok bool |
| 320 | err error |
| 321 | _ = err |
| 322 | ) |
| 323 | |
| 324 | val, ok = pathParams["SerialNumber"] |
| 325 | if !ok { |
| 326 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "SerialNumber") |
| 327 | } |
| 328 | |
| 329 | protoReq.SerialNumber, err = runtime.String(val) |
| 330 | |
| 331 | if err != nil { |
| 332 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "SerialNumber", err) |
| 333 | } |
| 334 | |
| 335 | msg, err := server.PoweronONU(ctx, &protoReq) |
| 336 | return msg, metadata, err |
| 337 | |
| 338 | } |
| 339 | |
Pragya Arya | bd731ec | 2020-02-11 16:38:17 +0530 | [diff] [blame^] | 340 | func request_BBSim_PoweronAllONUs_0(ctx context.Context, marshaler runtime.Marshaler, client BBSimClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 341 | var protoReq Empty |
| 342 | var metadata runtime.ServerMetadata |
| 343 | |
| 344 | msg, err := client.PoweronAllONUs(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) |
| 345 | return msg, metadata, err |
| 346 | |
| 347 | } |
| 348 | |
| 349 | func local_request_BBSim_PoweronAllONUs_0(ctx context.Context, marshaler runtime.Marshaler, server BBSimServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 350 | var protoReq Empty |
| 351 | var metadata runtime.ServerMetadata |
| 352 | |
| 353 | msg, err := server.PoweronAllONUs(ctx, &protoReq) |
| 354 | return msg, metadata, err |
| 355 | |
| 356 | } |
| 357 | |
| 358 | func request_BBSim_PoweronONUsOnPON_0(ctx context.Context, marshaler runtime.Marshaler, client BBSimClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 359 | var protoReq PONRequest |
| 360 | var metadata runtime.ServerMetadata |
| 361 | |
| 362 | var ( |
| 363 | val string |
| 364 | ok bool |
| 365 | err error |
| 366 | _ = err |
| 367 | ) |
| 368 | |
| 369 | val, ok = pathParams["PonPortId"] |
| 370 | if !ok { |
| 371 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "PonPortId") |
| 372 | } |
| 373 | |
| 374 | protoReq.PonPortId, err = runtime.Uint32(val) |
| 375 | |
| 376 | if err != nil { |
| 377 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "PonPortId", err) |
| 378 | } |
| 379 | |
| 380 | msg, err := client.PoweronONUsOnPON(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) |
| 381 | return msg, metadata, err |
| 382 | |
| 383 | } |
| 384 | |
| 385 | func local_request_BBSim_PoweronONUsOnPON_0(ctx context.Context, marshaler runtime.Marshaler, server BBSimServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 386 | var protoReq PONRequest |
| 387 | var metadata runtime.ServerMetadata |
| 388 | |
| 389 | var ( |
| 390 | val string |
| 391 | ok bool |
| 392 | err error |
| 393 | _ = err |
| 394 | ) |
| 395 | |
| 396 | val, ok = pathParams["PonPortId"] |
| 397 | if !ok { |
| 398 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "PonPortId") |
| 399 | } |
| 400 | |
| 401 | protoReq.PonPortId, err = runtime.Uint32(val) |
| 402 | |
| 403 | if err != nil { |
| 404 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "PonPortId", err) |
| 405 | } |
| 406 | |
| 407 | msg, err := server.PoweronONUsOnPON(ctx, &protoReq) |
| 408 | return msg, metadata, err |
| 409 | |
| 410 | } |
| 411 | |
Pragya Arya | 694ece0 | 2020-02-07 13:03:47 +0530 | [diff] [blame] | 412 | var ( |
Anand S Katti | 86552f9 | 2020-03-03 21:56:32 +0530 | [diff] [blame] | 413 | filter_BBSim_SetOnuAlarmIndication_0 = &utilities.DoubleArray{Encoding: map[string]int{"SerialNumber": 0, "AlarmType": 1, "Status": 2}, Base: []int{1, 1, 2, 3, 0, 0, 0}, Check: []int{0, 1, 1, 1, 2, 3, 4}} |
Pragya Arya | 694ece0 | 2020-02-07 13:03:47 +0530 | [diff] [blame] | 414 | ) |
| 415 | |
Anand S Katti | 86552f9 | 2020-03-03 21:56:32 +0530 | [diff] [blame] | 416 | func request_BBSim_SetOnuAlarmIndication_0(ctx context.Context, marshaler runtime.Marshaler, client BBSimClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 417 | var protoReq ONUAlarmRequest |
Pragya Arya | 694ece0 | 2020-02-07 13:03:47 +0530 | [diff] [blame] | 418 | var metadata runtime.ServerMetadata |
| 419 | |
| 420 | var ( |
| 421 | val string |
| 422 | ok bool |
| 423 | err error |
| 424 | _ = err |
| 425 | ) |
| 426 | |
| 427 | val, ok = pathParams["SerialNumber"] |
| 428 | if !ok { |
| 429 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "SerialNumber") |
| 430 | } |
| 431 | |
| 432 | protoReq.SerialNumber, err = runtime.String(val) |
| 433 | |
| 434 | if err != nil { |
| 435 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "SerialNumber", err) |
| 436 | } |
| 437 | |
| 438 | val, ok = pathParams["AlarmType"] |
| 439 | if !ok { |
| 440 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "AlarmType") |
| 441 | } |
| 442 | |
| 443 | protoReq.AlarmType, err = runtime.String(val) |
| 444 | |
| 445 | if err != nil { |
| 446 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "AlarmType", err) |
| 447 | } |
| 448 | |
| 449 | val, ok = pathParams["Status"] |
| 450 | if !ok { |
| 451 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "Status") |
| 452 | } |
| 453 | |
| 454 | protoReq.Status, err = runtime.String(val) |
| 455 | |
| 456 | if err != nil { |
| 457 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "Status", err) |
| 458 | } |
| 459 | |
| 460 | if err := req.ParseForm(); err != nil { |
| 461 | return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) |
| 462 | } |
Anand S Katti | 86552f9 | 2020-03-03 21:56:32 +0530 | [diff] [blame] | 463 | if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_BBSim_SetOnuAlarmIndication_0); err != nil { |
Pragya Arya | 694ece0 | 2020-02-07 13:03:47 +0530 | [diff] [blame] | 464 | return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) |
| 465 | } |
| 466 | |
Anand S Katti | 86552f9 | 2020-03-03 21:56:32 +0530 | [diff] [blame] | 467 | msg, err := client.SetOnuAlarmIndication(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) |
Pragya Arya | 694ece0 | 2020-02-07 13:03:47 +0530 | [diff] [blame] | 468 | return msg, metadata, err |
| 469 | |
| 470 | } |
| 471 | |
Anand S Katti | 86552f9 | 2020-03-03 21:56:32 +0530 | [diff] [blame] | 472 | func local_request_BBSim_SetOnuAlarmIndication_0(ctx context.Context, marshaler runtime.Marshaler, server BBSimServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 473 | var protoReq ONUAlarmRequest |
Pragya Arya | 694ece0 | 2020-02-07 13:03:47 +0530 | [diff] [blame] | 474 | var metadata runtime.ServerMetadata |
| 475 | |
| 476 | var ( |
| 477 | val string |
| 478 | ok bool |
| 479 | err error |
| 480 | _ = err |
| 481 | ) |
| 482 | |
| 483 | val, ok = pathParams["SerialNumber"] |
| 484 | if !ok { |
| 485 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "SerialNumber") |
| 486 | } |
| 487 | |
| 488 | protoReq.SerialNumber, err = runtime.String(val) |
| 489 | |
| 490 | if err != nil { |
| 491 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "SerialNumber", err) |
| 492 | } |
| 493 | |
| 494 | val, ok = pathParams["AlarmType"] |
| 495 | if !ok { |
| 496 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "AlarmType") |
| 497 | } |
| 498 | |
| 499 | protoReq.AlarmType, err = runtime.String(val) |
| 500 | |
| 501 | if err != nil { |
| 502 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "AlarmType", err) |
| 503 | } |
| 504 | |
| 505 | val, ok = pathParams["Status"] |
| 506 | if !ok { |
| 507 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "Status") |
| 508 | } |
| 509 | |
| 510 | protoReq.Status, err = runtime.String(val) |
| 511 | |
| 512 | if err != nil { |
| 513 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "Status", err) |
| 514 | } |
| 515 | |
Anand S Katti | 86552f9 | 2020-03-03 21:56:32 +0530 | [diff] [blame] | 516 | if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_BBSim_SetOnuAlarmIndication_0); err != nil { |
Pragya Arya | 694ece0 | 2020-02-07 13:03:47 +0530 | [diff] [blame] | 517 | return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) |
| 518 | } |
| 519 | |
Anand S Katti | 86552f9 | 2020-03-03 21:56:32 +0530 | [diff] [blame] | 520 | msg, err := server.SetOnuAlarmIndication(ctx, &protoReq) |
| 521 | return msg, metadata, err |
| 522 | |
| 523 | } |
| 524 | |
| 525 | func request_BBSim_SetOltAlarmIndication_0(ctx context.Context, marshaler runtime.Marshaler, client BBSimClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 526 | var protoReq OLTAlarmRequest |
| 527 | var metadata runtime.ServerMetadata |
| 528 | |
| 529 | var ( |
| 530 | val string |
| 531 | ok bool |
| 532 | err error |
| 533 | _ = err |
| 534 | ) |
| 535 | |
| 536 | val, ok = pathParams["InterfaceType"] |
| 537 | if !ok { |
| 538 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "InterfaceType") |
| 539 | } |
| 540 | |
| 541 | protoReq.InterfaceType, err = runtime.String(val) |
| 542 | |
| 543 | if err != nil { |
| 544 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "InterfaceType", err) |
| 545 | } |
| 546 | |
| 547 | val, ok = pathParams["InterfaceID"] |
| 548 | if !ok { |
| 549 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "InterfaceID") |
| 550 | } |
| 551 | |
| 552 | protoReq.InterfaceID, err = runtime.Uint32(val) |
| 553 | |
| 554 | if err != nil { |
| 555 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "InterfaceID", err) |
| 556 | } |
| 557 | |
| 558 | val, ok = pathParams["Status"] |
| 559 | if !ok { |
| 560 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "Status") |
| 561 | } |
| 562 | |
| 563 | protoReq.Status, err = runtime.String(val) |
| 564 | |
| 565 | if err != nil { |
| 566 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "Status", err) |
| 567 | } |
| 568 | |
| 569 | msg, err := client.SetOltAlarmIndication(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) |
| 570 | return msg, metadata, err |
| 571 | |
| 572 | } |
| 573 | |
| 574 | func local_request_BBSim_SetOltAlarmIndication_0(ctx context.Context, marshaler runtime.Marshaler, server BBSimServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 575 | var protoReq OLTAlarmRequest |
| 576 | var metadata runtime.ServerMetadata |
| 577 | |
| 578 | var ( |
| 579 | val string |
| 580 | ok bool |
| 581 | err error |
| 582 | _ = err |
| 583 | ) |
| 584 | |
| 585 | val, ok = pathParams["InterfaceType"] |
| 586 | if !ok { |
| 587 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "InterfaceType") |
| 588 | } |
| 589 | |
| 590 | protoReq.InterfaceType, err = runtime.String(val) |
| 591 | |
| 592 | if err != nil { |
| 593 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "InterfaceType", err) |
| 594 | } |
| 595 | |
| 596 | val, ok = pathParams["InterfaceID"] |
| 597 | if !ok { |
| 598 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "InterfaceID") |
| 599 | } |
| 600 | |
| 601 | protoReq.InterfaceID, err = runtime.Uint32(val) |
| 602 | |
| 603 | if err != nil { |
| 604 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "InterfaceID", err) |
| 605 | } |
| 606 | |
| 607 | val, ok = pathParams["Status"] |
| 608 | if !ok { |
| 609 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "Status") |
| 610 | } |
| 611 | |
| 612 | protoReq.Status, err = runtime.String(val) |
| 613 | |
| 614 | if err != nil { |
| 615 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "Status", err) |
| 616 | } |
| 617 | |
| 618 | msg, err := server.SetOltAlarmIndication(ctx, &protoReq) |
Pragya Arya | 694ece0 | 2020-02-07 13:03:47 +0530 | [diff] [blame] | 619 | return msg, metadata, err |
| 620 | |
| 621 | } |
| 622 | |
Pragya Arya | 8bdb453 | 2020-03-02 17:08:09 +0530 | [diff] [blame] | 623 | func request_BBSim_GetFlows_0(ctx context.Context, marshaler runtime.Marshaler, client BBSimClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 624 | var protoReq ONURequest |
| 625 | var metadata runtime.ServerMetadata |
| 626 | |
| 627 | var ( |
| 628 | val string |
| 629 | ok bool |
| 630 | err error |
| 631 | _ = err |
| 632 | ) |
| 633 | |
| 634 | val, ok = pathParams["SerialNumber"] |
| 635 | if !ok { |
| 636 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "SerialNumber") |
| 637 | } |
| 638 | |
| 639 | protoReq.SerialNumber, err = runtime.String(val) |
| 640 | |
| 641 | if err != nil { |
| 642 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "SerialNumber", err) |
| 643 | } |
| 644 | |
| 645 | msg, err := client.GetFlows(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) |
| 646 | return msg, metadata, err |
| 647 | |
| 648 | } |
| 649 | |
| 650 | func local_request_BBSim_GetFlows_0(ctx context.Context, marshaler runtime.Marshaler, server BBSimServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 651 | var protoReq ONURequest |
| 652 | var metadata runtime.ServerMetadata |
| 653 | |
| 654 | var ( |
| 655 | val string |
| 656 | ok bool |
| 657 | err error |
| 658 | _ = err |
| 659 | ) |
| 660 | |
| 661 | val, ok = pathParams["SerialNumber"] |
| 662 | if !ok { |
| 663 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "SerialNumber") |
| 664 | } |
| 665 | |
| 666 | protoReq.SerialNumber, err = runtime.String(val) |
| 667 | |
| 668 | if err != nil { |
| 669 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "SerialNumber", err) |
| 670 | } |
| 671 | |
| 672 | msg, err := server.GetFlows(ctx, &protoReq) |
| 673 | return msg, metadata, err |
| 674 | |
| 675 | } |
| 676 | |
| 677 | var ( |
| 678 | filter_BBSim_GetFlows_1 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} |
| 679 | ) |
| 680 | |
| 681 | func request_BBSim_GetFlows_1(ctx context.Context, marshaler runtime.Marshaler, client BBSimClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 682 | var protoReq ONURequest |
| 683 | var metadata runtime.ServerMetadata |
| 684 | |
| 685 | if err := req.ParseForm(); err != nil { |
| 686 | return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) |
| 687 | } |
| 688 | if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_BBSim_GetFlows_1); err != nil { |
| 689 | return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) |
| 690 | } |
| 691 | |
| 692 | msg, err := client.GetFlows(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) |
| 693 | return msg, metadata, err |
| 694 | |
| 695 | } |
| 696 | |
| 697 | func local_request_BBSim_GetFlows_1(ctx context.Context, marshaler runtime.Marshaler, server BBSimServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 698 | var protoReq ONURequest |
| 699 | var metadata runtime.ServerMetadata |
| 700 | |
| 701 | if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_BBSim_GetFlows_1); err != nil { |
| 702 | return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) |
| 703 | } |
| 704 | |
| 705 | msg, err := server.GetFlows(ctx, &protoReq) |
| 706 | return msg, metadata, err |
| 707 | |
| 708 | } |
| 709 | |
Anand S Katti | 0954135 | 2020-01-29 15:54:01 +0530 | [diff] [blame] | 710 | func request_BBSim_GetOnuTrafficSchedulers_0(ctx context.Context, marshaler runtime.Marshaler, client BBSimClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 711 | var protoReq ONURequest |
| 712 | var metadata runtime.ServerMetadata |
| 713 | |
| 714 | var ( |
| 715 | val string |
| 716 | ok bool |
| 717 | err error |
| 718 | _ = err |
| 719 | ) |
| 720 | |
| 721 | val, ok = pathParams["SerialNumber"] |
| 722 | if !ok { |
| 723 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "SerialNumber") |
| 724 | } |
| 725 | |
| 726 | protoReq.SerialNumber, err = runtime.String(val) |
| 727 | |
| 728 | if err != nil { |
| 729 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "SerialNumber", err) |
| 730 | } |
| 731 | |
| 732 | msg, err := client.GetOnuTrafficSchedulers(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) |
| 733 | return msg, metadata, err |
| 734 | |
| 735 | } |
| 736 | |
| 737 | func local_request_BBSim_GetOnuTrafficSchedulers_0(ctx context.Context, marshaler runtime.Marshaler, server BBSimServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { |
| 738 | var protoReq ONURequest |
| 739 | var metadata runtime.ServerMetadata |
| 740 | |
| 741 | var ( |
| 742 | val string |
| 743 | ok bool |
| 744 | err error |
| 745 | _ = err |
| 746 | ) |
| 747 | |
| 748 | val, ok = pathParams["SerialNumber"] |
| 749 | if !ok { |
| 750 | return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "SerialNumber") |
| 751 | } |
| 752 | |
| 753 | protoReq.SerialNumber, err = runtime.String(val) |
| 754 | |
| 755 | if err != nil { |
| 756 | return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "SerialNumber", err) |
| 757 | } |
| 758 | |
| 759 | msg, err := server.GetOnuTrafficSchedulers(ctx, &protoReq) |
| 760 | return msg, metadata, err |
| 761 | |
| 762 | } |
| 763 | |
Pragya Arya | 1cbefa4 | 2020-01-13 12:15:29 +0530 | [diff] [blame] | 764 | // RegisterBBSimHandlerServer registers the http handlers for service BBSim to "mux". |
| 765 | // UnaryRPC :call BBSimServer directly. |
| 766 | // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. |
| 767 | func RegisterBBSimHandlerServer(ctx context.Context, mux *runtime.ServeMux, server BBSimServer) error { |
| 768 | |
| 769 | mux.Handle("GET", pattern_BBSim_Version_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 770 | ctx, cancel := context.WithCancel(req.Context()) |
| 771 | defer cancel() |
| 772 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 773 | rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) |
| 774 | if err != nil { |
| 775 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 776 | return |
| 777 | } |
| 778 | resp, md, err := local_request_BBSim_Version_0(rctx, inboundMarshaler, server, req, pathParams) |
| 779 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 780 | if err != nil { |
| 781 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 782 | return |
| 783 | } |
| 784 | |
| 785 | forward_BBSim_Version_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 786 | |
| 787 | }) |
| 788 | |
| 789 | mux.Handle("GET", pattern_BBSim_GetOlt_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 790 | ctx, cancel := context.WithCancel(req.Context()) |
| 791 | defer cancel() |
| 792 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 793 | rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) |
| 794 | if err != nil { |
| 795 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 796 | return |
| 797 | } |
| 798 | resp, md, err := local_request_BBSim_GetOlt_0(rctx, inboundMarshaler, server, req, pathParams) |
| 799 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 800 | if err != nil { |
| 801 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 802 | return |
| 803 | } |
| 804 | |
| 805 | forward_BBSim_GetOlt_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 806 | |
| 807 | }) |
| 808 | |
| 809 | mux.Handle("GET", pattern_BBSim_GetOlt_1, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 810 | ctx, cancel := context.WithCancel(req.Context()) |
| 811 | defer cancel() |
| 812 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 813 | rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) |
| 814 | if err != nil { |
| 815 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 816 | return |
| 817 | } |
| 818 | resp, md, err := local_request_BBSim_GetOlt_1(rctx, inboundMarshaler, server, req, pathParams) |
| 819 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 820 | if err != nil { |
| 821 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 822 | return |
| 823 | } |
| 824 | |
| 825 | forward_BBSim_GetOlt_1(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 826 | |
| 827 | }) |
| 828 | |
Pragya Arya | 1cbefa4 | 2020-01-13 12:15:29 +0530 | [diff] [blame] | 829 | mux.Handle("GET", pattern_BBSim_GetONU_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 830 | ctx, cancel := context.WithCancel(req.Context()) |
| 831 | defer cancel() |
| 832 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 833 | rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) |
| 834 | if err != nil { |
| 835 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 836 | return |
| 837 | } |
| 838 | resp, md, err := local_request_BBSim_GetONU_0(rctx, inboundMarshaler, server, req, pathParams) |
| 839 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 840 | if err != nil { |
| 841 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 842 | return |
| 843 | } |
| 844 | |
| 845 | forward_BBSim_GetONU_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 846 | |
| 847 | }) |
| 848 | |
Pragya Arya | bd731ec | 2020-02-11 16:38:17 +0530 | [diff] [blame^] | 849 | mux.Handle("GET", pattern_BBSim_GetONUs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 850 | ctx, cancel := context.WithCancel(req.Context()) |
| 851 | defer cancel() |
| 852 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 853 | rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) |
| 854 | if err != nil { |
| 855 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 856 | return |
| 857 | } |
| 858 | resp, md, err := local_request_BBSim_GetONUs_0(rctx, inboundMarshaler, server, req, pathParams) |
| 859 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 860 | if err != nil { |
| 861 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 862 | return |
| 863 | } |
| 864 | |
| 865 | forward_BBSim_GetONUs_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 866 | |
| 867 | }) |
| 868 | |
Pragya Arya | 1cbefa4 | 2020-01-13 12:15:29 +0530 | [diff] [blame] | 869 | mux.Handle("DELETE", pattern_BBSim_ShutdownONU_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 870 | ctx, cancel := context.WithCancel(req.Context()) |
| 871 | defer cancel() |
| 872 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 873 | rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) |
| 874 | if err != nil { |
| 875 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 876 | return |
| 877 | } |
| 878 | resp, md, err := local_request_BBSim_ShutdownONU_0(rctx, inboundMarshaler, server, req, pathParams) |
| 879 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 880 | if err != nil { |
| 881 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 882 | return |
| 883 | } |
| 884 | |
| 885 | forward_BBSim_ShutdownONU_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 886 | |
| 887 | }) |
| 888 | |
Pragya Arya | bd731ec | 2020-02-11 16:38:17 +0530 | [diff] [blame^] | 889 | mux.Handle("DELETE", pattern_BBSim_ShutdownAllONUs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 890 | ctx, cancel := context.WithCancel(req.Context()) |
| 891 | defer cancel() |
| 892 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 893 | rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) |
| 894 | if err != nil { |
| 895 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 896 | return |
| 897 | } |
| 898 | resp, md, err := local_request_BBSim_ShutdownAllONUs_0(rctx, inboundMarshaler, server, req, pathParams) |
| 899 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 900 | if err != nil { |
| 901 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 902 | return |
| 903 | } |
| 904 | |
| 905 | forward_BBSim_ShutdownAllONUs_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 906 | |
| 907 | }) |
| 908 | |
| 909 | mux.Handle("DELETE", pattern_BBSim_ShutdownONUsOnPON_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 910 | ctx, cancel := context.WithCancel(req.Context()) |
| 911 | defer cancel() |
| 912 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 913 | rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) |
| 914 | if err != nil { |
| 915 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 916 | return |
| 917 | } |
| 918 | resp, md, err := local_request_BBSim_ShutdownONUsOnPON_0(rctx, inboundMarshaler, server, req, pathParams) |
| 919 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 920 | if err != nil { |
| 921 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 922 | return |
| 923 | } |
| 924 | |
| 925 | forward_BBSim_ShutdownONUsOnPON_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 926 | |
| 927 | }) |
| 928 | |
Pragya Arya | 1cbefa4 | 2020-01-13 12:15:29 +0530 | [diff] [blame] | 929 | mux.Handle("POST", pattern_BBSim_PoweronONU_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 930 | ctx, cancel := context.WithCancel(req.Context()) |
| 931 | defer cancel() |
| 932 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 933 | rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) |
| 934 | if err != nil { |
| 935 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 936 | return |
| 937 | } |
| 938 | resp, md, err := local_request_BBSim_PoweronONU_0(rctx, inboundMarshaler, server, req, pathParams) |
| 939 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 940 | if err != nil { |
| 941 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 942 | return |
| 943 | } |
| 944 | |
| 945 | forward_BBSim_PoweronONU_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 946 | |
| 947 | }) |
| 948 | |
Pragya Arya | bd731ec | 2020-02-11 16:38:17 +0530 | [diff] [blame^] | 949 | mux.Handle("POST", pattern_BBSim_PoweronAllONUs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 950 | ctx, cancel := context.WithCancel(req.Context()) |
| 951 | defer cancel() |
| 952 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 953 | rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) |
| 954 | if err != nil { |
| 955 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 956 | return |
| 957 | } |
| 958 | resp, md, err := local_request_BBSim_PoweronAllONUs_0(rctx, inboundMarshaler, server, req, pathParams) |
| 959 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 960 | if err != nil { |
| 961 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 962 | return |
| 963 | } |
| 964 | |
| 965 | forward_BBSim_PoweronAllONUs_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 966 | |
| 967 | }) |
| 968 | |
| 969 | mux.Handle("POST", pattern_BBSim_PoweronONUsOnPON_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 970 | ctx, cancel := context.WithCancel(req.Context()) |
| 971 | defer cancel() |
| 972 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 973 | rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) |
| 974 | if err != nil { |
| 975 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 976 | return |
| 977 | } |
| 978 | resp, md, err := local_request_BBSim_PoweronONUsOnPON_0(rctx, inboundMarshaler, server, req, pathParams) |
| 979 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 980 | if err != nil { |
| 981 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 982 | return |
| 983 | } |
| 984 | |
| 985 | forward_BBSim_PoweronONUsOnPON_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 986 | |
| 987 | }) |
| 988 | |
Anand S Katti | 86552f9 | 2020-03-03 21:56:32 +0530 | [diff] [blame] | 989 | mux.Handle("POST", pattern_BBSim_SetOnuAlarmIndication_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
Pragya Arya | 694ece0 | 2020-02-07 13:03:47 +0530 | [diff] [blame] | 990 | ctx, cancel := context.WithCancel(req.Context()) |
| 991 | defer cancel() |
| 992 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 993 | rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) |
| 994 | if err != nil { |
| 995 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 996 | return |
| 997 | } |
Anand S Katti | 86552f9 | 2020-03-03 21:56:32 +0530 | [diff] [blame] | 998 | resp, md, err := local_request_BBSim_SetOnuAlarmIndication_0(rctx, inboundMarshaler, server, req, pathParams) |
Pragya Arya | 694ece0 | 2020-02-07 13:03:47 +0530 | [diff] [blame] | 999 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 1000 | if err != nil { |
| 1001 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1002 | return |
| 1003 | } |
| 1004 | |
Anand S Katti | 86552f9 | 2020-03-03 21:56:32 +0530 | [diff] [blame] | 1005 | forward_BBSim_SetOnuAlarmIndication_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 1006 | |
| 1007 | }) |
| 1008 | |
| 1009 | mux.Handle("POST", pattern_BBSim_SetOltAlarmIndication_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 1010 | ctx, cancel := context.WithCancel(req.Context()) |
| 1011 | defer cancel() |
| 1012 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 1013 | rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) |
| 1014 | if err != nil { |
| 1015 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1016 | return |
| 1017 | } |
| 1018 | resp, md, err := local_request_BBSim_SetOltAlarmIndication_0(rctx, inboundMarshaler, server, req, pathParams) |
| 1019 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 1020 | if err != nil { |
| 1021 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1022 | return |
| 1023 | } |
| 1024 | |
| 1025 | forward_BBSim_SetOltAlarmIndication_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
Pragya Arya | 694ece0 | 2020-02-07 13:03:47 +0530 | [diff] [blame] | 1026 | |
| 1027 | }) |
| 1028 | |
Pragya Arya | 8bdb453 | 2020-03-02 17:08:09 +0530 | [diff] [blame] | 1029 | mux.Handle("GET", pattern_BBSim_GetFlows_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 1030 | ctx, cancel := context.WithCancel(req.Context()) |
| 1031 | defer cancel() |
| 1032 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 1033 | rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) |
| 1034 | if err != nil { |
| 1035 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1036 | return |
| 1037 | } |
| 1038 | resp, md, err := local_request_BBSim_GetFlows_0(rctx, inboundMarshaler, server, req, pathParams) |
| 1039 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 1040 | if err != nil { |
| 1041 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1042 | return |
| 1043 | } |
| 1044 | |
| 1045 | forward_BBSim_GetFlows_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 1046 | |
| 1047 | }) |
| 1048 | |
| 1049 | mux.Handle("GET", pattern_BBSim_GetFlows_1, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 1050 | ctx, cancel := context.WithCancel(req.Context()) |
| 1051 | defer cancel() |
| 1052 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 1053 | rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) |
| 1054 | if err != nil { |
| 1055 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1056 | return |
| 1057 | } |
| 1058 | resp, md, err := local_request_BBSim_GetFlows_1(rctx, inboundMarshaler, server, req, pathParams) |
| 1059 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 1060 | if err != nil { |
| 1061 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1062 | return |
| 1063 | } |
| 1064 | |
| 1065 | forward_BBSim_GetFlows_1(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 1066 | |
| 1067 | }) |
| 1068 | |
Anand S Katti | 0954135 | 2020-01-29 15:54:01 +0530 | [diff] [blame] | 1069 | mux.Handle("GET", pattern_BBSim_GetOnuTrafficSchedulers_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 1070 | ctx, cancel := context.WithCancel(req.Context()) |
| 1071 | defer cancel() |
| 1072 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 1073 | rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) |
| 1074 | if err != nil { |
| 1075 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1076 | return |
| 1077 | } |
| 1078 | resp, md, err := local_request_BBSim_GetOnuTrafficSchedulers_0(rctx, inboundMarshaler, server, req, pathParams) |
| 1079 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 1080 | if err != nil { |
| 1081 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1082 | return |
| 1083 | } |
| 1084 | |
| 1085 | forward_BBSim_GetOnuTrafficSchedulers_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 1086 | |
| 1087 | }) |
| 1088 | |
Pragya Arya | 1cbefa4 | 2020-01-13 12:15:29 +0530 | [diff] [blame] | 1089 | return nil |
| 1090 | } |
| 1091 | |
Matteo Scandolo | a6a3aee | 2019-11-26 13:30:14 -0700 | [diff] [blame] | 1092 | // RegisterBBSimHandlerFromEndpoint is same as RegisterBBSimHandler but |
| 1093 | // automatically dials to "endpoint" and closes the connection when "ctx" gets done. |
| 1094 | func RegisterBBSimHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { |
| 1095 | conn, err := grpc.Dial(endpoint, opts...) |
| 1096 | if err != nil { |
| 1097 | return err |
| 1098 | } |
| 1099 | defer func() { |
| 1100 | if err != nil { |
| 1101 | if cerr := conn.Close(); cerr != nil { |
| 1102 | grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) |
| 1103 | } |
| 1104 | return |
| 1105 | } |
| 1106 | go func() { |
| 1107 | <-ctx.Done() |
| 1108 | if cerr := conn.Close(); cerr != nil { |
| 1109 | grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) |
| 1110 | } |
| 1111 | }() |
| 1112 | }() |
| 1113 | |
| 1114 | return RegisterBBSimHandler(ctx, mux, conn) |
| 1115 | } |
| 1116 | |
| 1117 | // RegisterBBSimHandler registers the http handlers for service BBSim to "mux". |
| 1118 | // The handlers forward requests to the grpc endpoint over "conn". |
| 1119 | func RegisterBBSimHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error { |
| 1120 | return RegisterBBSimHandlerClient(ctx, mux, NewBBSimClient(conn)) |
| 1121 | } |
| 1122 | |
| 1123 | // RegisterBBSimHandlerClient registers the http handlers for service BBSim |
| 1124 | // to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "BBSimClient". |
| 1125 | // Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "BBSimClient" |
| 1126 | // doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in |
| 1127 | // "BBSimClient" to call the correct interceptors. |
| 1128 | func RegisterBBSimHandlerClient(ctx context.Context, mux *runtime.ServeMux, client BBSimClient) error { |
| 1129 | |
| 1130 | mux.Handle("GET", pattern_BBSim_Version_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 1131 | ctx, cancel := context.WithCancel(req.Context()) |
| 1132 | defer cancel() |
| 1133 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 1134 | rctx, err := runtime.AnnotateContext(ctx, mux, req) |
| 1135 | if err != nil { |
| 1136 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1137 | return |
| 1138 | } |
| 1139 | resp, md, err := request_BBSim_Version_0(rctx, inboundMarshaler, client, req, pathParams) |
| 1140 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 1141 | if err != nil { |
| 1142 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1143 | return |
| 1144 | } |
| 1145 | |
| 1146 | forward_BBSim_Version_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 1147 | |
| 1148 | }) |
| 1149 | |
| 1150 | mux.Handle("GET", pattern_BBSim_GetOlt_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 1151 | ctx, cancel := context.WithCancel(req.Context()) |
| 1152 | defer cancel() |
| 1153 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 1154 | rctx, err := runtime.AnnotateContext(ctx, mux, req) |
| 1155 | if err != nil { |
| 1156 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1157 | return |
| 1158 | } |
| 1159 | resp, md, err := request_BBSim_GetOlt_0(rctx, inboundMarshaler, client, req, pathParams) |
| 1160 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 1161 | if err != nil { |
| 1162 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1163 | return |
| 1164 | } |
| 1165 | |
| 1166 | forward_BBSim_GetOlt_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 1167 | |
| 1168 | }) |
| 1169 | |
| 1170 | mux.Handle("GET", pattern_BBSim_GetOlt_1, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 1171 | ctx, cancel := context.WithCancel(req.Context()) |
| 1172 | defer cancel() |
| 1173 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 1174 | rctx, err := runtime.AnnotateContext(ctx, mux, req) |
| 1175 | if err != nil { |
| 1176 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1177 | return |
| 1178 | } |
| 1179 | resp, md, err := request_BBSim_GetOlt_1(rctx, inboundMarshaler, client, req, pathParams) |
| 1180 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 1181 | if err != nil { |
| 1182 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1183 | return |
| 1184 | } |
| 1185 | |
| 1186 | forward_BBSim_GetOlt_1(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 1187 | |
| 1188 | }) |
| 1189 | |
Matteo Scandolo | a6a3aee | 2019-11-26 13:30:14 -0700 | [diff] [blame] | 1190 | mux.Handle("GET", pattern_BBSim_GetONU_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 1191 | ctx, cancel := context.WithCancel(req.Context()) |
| 1192 | defer cancel() |
| 1193 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 1194 | rctx, err := runtime.AnnotateContext(ctx, mux, req) |
| 1195 | if err != nil { |
| 1196 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1197 | return |
| 1198 | } |
| 1199 | resp, md, err := request_BBSim_GetONU_0(rctx, inboundMarshaler, client, req, pathParams) |
| 1200 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 1201 | if err != nil { |
| 1202 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1203 | return |
| 1204 | } |
| 1205 | |
| 1206 | forward_BBSim_GetONU_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 1207 | |
| 1208 | }) |
| 1209 | |
Pragya Arya | bd731ec | 2020-02-11 16:38:17 +0530 | [diff] [blame^] | 1210 | mux.Handle("GET", pattern_BBSim_GetONUs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 1211 | ctx, cancel := context.WithCancel(req.Context()) |
| 1212 | defer cancel() |
| 1213 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 1214 | rctx, err := runtime.AnnotateContext(ctx, mux, req) |
| 1215 | if err != nil { |
| 1216 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1217 | return |
| 1218 | } |
| 1219 | resp, md, err := request_BBSim_GetONUs_0(rctx, inboundMarshaler, client, req, pathParams) |
| 1220 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 1221 | if err != nil { |
| 1222 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1223 | return |
| 1224 | } |
| 1225 | |
| 1226 | forward_BBSim_GetONUs_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 1227 | |
| 1228 | }) |
| 1229 | |
Pragya Arya | 1cbefa4 | 2020-01-13 12:15:29 +0530 | [diff] [blame] | 1230 | mux.Handle("DELETE", pattern_BBSim_ShutdownONU_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 1231 | ctx, cancel := context.WithCancel(req.Context()) |
| 1232 | defer cancel() |
| 1233 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 1234 | rctx, err := runtime.AnnotateContext(ctx, mux, req) |
| 1235 | if err != nil { |
| 1236 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1237 | return |
| 1238 | } |
| 1239 | resp, md, err := request_BBSim_ShutdownONU_0(rctx, inboundMarshaler, client, req, pathParams) |
| 1240 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 1241 | if err != nil { |
| 1242 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1243 | return |
| 1244 | } |
| 1245 | |
| 1246 | forward_BBSim_ShutdownONU_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 1247 | |
| 1248 | }) |
| 1249 | |
Pragya Arya | bd731ec | 2020-02-11 16:38:17 +0530 | [diff] [blame^] | 1250 | mux.Handle("DELETE", pattern_BBSim_ShutdownAllONUs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 1251 | ctx, cancel := context.WithCancel(req.Context()) |
| 1252 | defer cancel() |
| 1253 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 1254 | rctx, err := runtime.AnnotateContext(ctx, mux, req) |
| 1255 | if err != nil { |
| 1256 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1257 | return |
| 1258 | } |
| 1259 | resp, md, err := request_BBSim_ShutdownAllONUs_0(rctx, inboundMarshaler, client, req, pathParams) |
| 1260 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 1261 | if err != nil { |
| 1262 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1263 | return |
| 1264 | } |
| 1265 | |
| 1266 | forward_BBSim_ShutdownAllONUs_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 1267 | |
| 1268 | }) |
| 1269 | |
| 1270 | mux.Handle("DELETE", pattern_BBSim_ShutdownONUsOnPON_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 1271 | ctx, cancel := context.WithCancel(req.Context()) |
| 1272 | defer cancel() |
| 1273 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 1274 | rctx, err := runtime.AnnotateContext(ctx, mux, req) |
| 1275 | if err != nil { |
| 1276 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1277 | return |
| 1278 | } |
| 1279 | resp, md, err := request_BBSim_ShutdownONUsOnPON_0(rctx, inboundMarshaler, client, req, pathParams) |
| 1280 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 1281 | if err != nil { |
| 1282 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1283 | return |
| 1284 | } |
| 1285 | |
| 1286 | forward_BBSim_ShutdownONUsOnPON_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 1287 | |
| 1288 | }) |
| 1289 | |
Pragya Arya | 1cbefa4 | 2020-01-13 12:15:29 +0530 | [diff] [blame] | 1290 | mux.Handle("POST", pattern_BBSim_PoweronONU_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 1291 | ctx, cancel := context.WithCancel(req.Context()) |
| 1292 | defer cancel() |
| 1293 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 1294 | rctx, err := runtime.AnnotateContext(ctx, mux, req) |
| 1295 | if err != nil { |
| 1296 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1297 | return |
| 1298 | } |
| 1299 | resp, md, err := request_BBSim_PoweronONU_0(rctx, inboundMarshaler, client, req, pathParams) |
| 1300 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 1301 | if err != nil { |
| 1302 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1303 | return |
| 1304 | } |
| 1305 | |
| 1306 | forward_BBSim_PoweronONU_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 1307 | |
| 1308 | }) |
| 1309 | |
Pragya Arya | bd731ec | 2020-02-11 16:38:17 +0530 | [diff] [blame^] | 1310 | mux.Handle("POST", pattern_BBSim_PoweronAllONUs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 1311 | ctx, cancel := context.WithCancel(req.Context()) |
| 1312 | defer cancel() |
| 1313 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 1314 | rctx, err := runtime.AnnotateContext(ctx, mux, req) |
| 1315 | if err != nil { |
| 1316 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1317 | return |
| 1318 | } |
| 1319 | resp, md, err := request_BBSim_PoweronAllONUs_0(rctx, inboundMarshaler, client, req, pathParams) |
| 1320 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 1321 | if err != nil { |
| 1322 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1323 | return |
| 1324 | } |
| 1325 | |
| 1326 | forward_BBSim_PoweronAllONUs_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 1327 | |
| 1328 | }) |
| 1329 | |
| 1330 | mux.Handle("POST", pattern_BBSim_PoweronONUsOnPON_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 1331 | ctx, cancel := context.WithCancel(req.Context()) |
| 1332 | defer cancel() |
| 1333 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 1334 | rctx, err := runtime.AnnotateContext(ctx, mux, req) |
| 1335 | if err != nil { |
| 1336 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1337 | return |
| 1338 | } |
| 1339 | resp, md, err := request_BBSim_PoweronONUsOnPON_0(rctx, inboundMarshaler, client, req, pathParams) |
| 1340 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 1341 | if err != nil { |
| 1342 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1343 | return |
| 1344 | } |
| 1345 | |
| 1346 | forward_BBSim_PoweronONUsOnPON_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 1347 | |
| 1348 | }) |
| 1349 | |
Anand S Katti | 86552f9 | 2020-03-03 21:56:32 +0530 | [diff] [blame] | 1350 | mux.Handle("POST", pattern_BBSim_SetOnuAlarmIndication_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
Pragya Arya | 694ece0 | 2020-02-07 13:03:47 +0530 | [diff] [blame] | 1351 | ctx, cancel := context.WithCancel(req.Context()) |
| 1352 | defer cancel() |
| 1353 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 1354 | rctx, err := runtime.AnnotateContext(ctx, mux, req) |
| 1355 | if err != nil { |
| 1356 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1357 | return |
| 1358 | } |
Anand S Katti | 86552f9 | 2020-03-03 21:56:32 +0530 | [diff] [blame] | 1359 | resp, md, err := request_BBSim_SetOnuAlarmIndication_0(rctx, inboundMarshaler, client, req, pathParams) |
Pragya Arya | 694ece0 | 2020-02-07 13:03:47 +0530 | [diff] [blame] | 1360 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 1361 | if err != nil { |
| 1362 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1363 | return |
| 1364 | } |
| 1365 | |
Anand S Katti | 86552f9 | 2020-03-03 21:56:32 +0530 | [diff] [blame] | 1366 | forward_BBSim_SetOnuAlarmIndication_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 1367 | |
| 1368 | }) |
| 1369 | |
| 1370 | mux.Handle("POST", pattern_BBSim_SetOltAlarmIndication_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 1371 | ctx, cancel := context.WithCancel(req.Context()) |
| 1372 | defer cancel() |
| 1373 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 1374 | rctx, err := runtime.AnnotateContext(ctx, mux, req) |
| 1375 | if err != nil { |
| 1376 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1377 | return |
| 1378 | } |
| 1379 | resp, md, err := request_BBSim_SetOltAlarmIndication_0(rctx, inboundMarshaler, client, req, pathParams) |
| 1380 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 1381 | if err != nil { |
| 1382 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1383 | return |
| 1384 | } |
| 1385 | |
| 1386 | forward_BBSim_SetOltAlarmIndication_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
Pragya Arya | 694ece0 | 2020-02-07 13:03:47 +0530 | [diff] [blame] | 1387 | |
| 1388 | }) |
| 1389 | |
Pragya Arya | 8bdb453 | 2020-03-02 17:08:09 +0530 | [diff] [blame] | 1390 | mux.Handle("GET", pattern_BBSim_GetFlows_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 1391 | ctx, cancel := context.WithCancel(req.Context()) |
| 1392 | defer cancel() |
| 1393 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 1394 | rctx, err := runtime.AnnotateContext(ctx, mux, req) |
| 1395 | if err != nil { |
| 1396 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1397 | return |
| 1398 | } |
| 1399 | resp, md, err := request_BBSim_GetFlows_0(rctx, inboundMarshaler, client, req, pathParams) |
| 1400 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 1401 | if err != nil { |
| 1402 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1403 | return |
| 1404 | } |
| 1405 | |
| 1406 | forward_BBSim_GetFlows_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 1407 | |
| 1408 | }) |
| 1409 | |
| 1410 | mux.Handle("GET", pattern_BBSim_GetFlows_1, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 1411 | ctx, cancel := context.WithCancel(req.Context()) |
| 1412 | defer cancel() |
| 1413 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 1414 | rctx, err := runtime.AnnotateContext(ctx, mux, req) |
| 1415 | if err != nil { |
| 1416 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1417 | return |
| 1418 | } |
| 1419 | resp, md, err := request_BBSim_GetFlows_1(rctx, inboundMarshaler, client, req, pathParams) |
| 1420 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 1421 | if err != nil { |
| 1422 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1423 | return |
| 1424 | } |
| 1425 | |
| 1426 | forward_BBSim_GetFlows_1(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 1427 | |
| 1428 | }) |
| 1429 | |
Anand S Katti | 0954135 | 2020-01-29 15:54:01 +0530 | [diff] [blame] | 1430 | mux.Handle("GET", pattern_BBSim_GetOnuTrafficSchedulers_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { |
| 1431 | ctx, cancel := context.WithCancel(req.Context()) |
| 1432 | defer cancel() |
| 1433 | inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) |
| 1434 | rctx, err := runtime.AnnotateContext(ctx, mux, req) |
| 1435 | if err != nil { |
| 1436 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1437 | return |
| 1438 | } |
| 1439 | resp, md, err := request_BBSim_GetOnuTrafficSchedulers_0(rctx, inboundMarshaler, client, req, pathParams) |
| 1440 | ctx = runtime.NewServerMetadataContext(ctx, md) |
| 1441 | if err != nil { |
| 1442 | runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) |
| 1443 | return |
| 1444 | } |
| 1445 | |
| 1446 | forward_BBSim_GetOnuTrafficSchedulers_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) |
| 1447 | |
| 1448 | }) |
| 1449 | |
Matteo Scandolo | a6a3aee | 2019-11-26 13:30:14 -0700 | [diff] [blame] | 1450 | return nil |
| 1451 | } |
| 1452 | |
| 1453 | var ( |
| 1454 | pattern_BBSim_Version_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "version"}, "", runtime.AssumeColonVerbOpt(true))) |
| 1455 | |
| 1456 | pattern_BBSim_GetOlt_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "olt"}, "", runtime.AssumeColonVerbOpt(true))) |
| 1457 | |
| 1458 | pattern_BBSim_GetOlt_1 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "olt", "status"}, "", runtime.AssumeColonVerbOpt(true))) |
| 1459 | |
Matteo Scandolo | a6a3aee | 2019-11-26 13:30:14 -0700 | [diff] [blame] | 1460 | pattern_BBSim_GetONU_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v1", "olt", "onus", "SerialNumber"}, "", runtime.AssumeColonVerbOpt(true))) |
Pragya Arya | 1cbefa4 | 2020-01-13 12:15:29 +0530 | [diff] [blame] | 1461 | |
Pragya Arya | bd731ec | 2020-02-11 16:38:17 +0530 | [diff] [blame^] | 1462 | pattern_BBSim_GetONUs_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "olt", "onus"}, "", runtime.AssumeColonVerbOpt(true))) |
| 1463 | |
Pragya Arya | 1cbefa4 | 2020-01-13 12:15:29 +0530 | [diff] [blame] | 1464 | pattern_BBSim_ShutdownONU_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v1", "olt", "onus", "SerialNumber"}, "", runtime.AssumeColonVerbOpt(true))) |
| 1465 | |
Pragya Arya | bd731ec | 2020-02-11 16:38:17 +0530 | [diff] [blame^] | 1466 | pattern_BBSim_ShutdownAllONUs_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "olt", "onus"}, "", runtime.AssumeColonVerbOpt(true))) |
| 1467 | |
| 1468 | pattern_BBSim_ShutdownONUsOnPON_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3, 2, 4}, []string{"v1", "olt", "port", "PonPortId", "onus"}, "", runtime.AssumeColonVerbOpt(true))) |
| 1469 | |
Pragya Arya | 1cbefa4 | 2020-01-13 12:15:29 +0530 | [diff] [blame] | 1470 | pattern_BBSim_PoweronONU_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v1", "olt", "onus", "SerialNumber"}, "", runtime.AssumeColonVerbOpt(true))) |
Pragya Arya | 694ece0 | 2020-02-07 13:03:47 +0530 | [diff] [blame] | 1471 | |
Pragya Arya | bd731ec | 2020-02-11 16:38:17 +0530 | [diff] [blame^] | 1472 | pattern_BBSim_PoweronAllONUs_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "olt", "onus"}, "", runtime.AssumeColonVerbOpt(true))) |
| 1473 | |
| 1474 | pattern_BBSim_PoweronONUsOnPON_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3, 2, 4}, []string{"v1", "olt", "port", "PonPortId", "onus"}, "", runtime.AssumeColonVerbOpt(true))) |
| 1475 | |
Anand S Katti | 86552f9 | 2020-03-03 21:56:32 +0530 | [diff] [blame] | 1476 | pattern_BBSim_SetOnuAlarmIndication_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3, 2, 4, 1, 0, 4, 1, 5, 5, 1, 0, 4, 1, 5, 6}, []string{"v1", "olt", "onus", "SerialNumber", "alarms", "AlarmType", "Status"}, "", runtime.AssumeColonVerbOpt(true))) |
| 1477 | |
| 1478 | pattern_BBSim_SetOltAlarmIndication_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3, 1, 0, 4, 1, 5, 4, 2, 5, 2, 6, 1, 0, 4, 1, 5, 7}, []string{"v1", "olt", "ports", "InterfaceType", "InterfaceID", "alarms", "los", "Status"}, "", runtime.AssumeColonVerbOpt(true))) |
Anand S Katti | 0954135 | 2020-01-29 15:54:01 +0530 | [diff] [blame] | 1479 | |
Pragya Arya | 8bdb453 | 2020-03-02 17:08:09 +0530 | [diff] [blame] | 1480 | pattern_BBSim_GetFlows_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3, 2, 4}, []string{"v1", "olt", "onus", "SerialNumber", "flows"}, "", runtime.AssumeColonVerbOpt(true))) |
| 1481 | |
| 1482 | pattern_BBSim_GetFlows_1 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "olt", "flows"}, "", runtime.AssumeColonVerbOpt(true))) |
| 1483 | |
Anand S Katti | 0954135 | 2020-01-29 15:54:01 +0530 | [diff] [blame] | 1484 | pattern_BBSim_GetOnuTrafficSchedulers_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3, 2, 4}, []string{"v1", "olt", "onus", "SerialNumber", "trafficschedulers"}, "", runtime.AssumeColonVerbOpt(true))) |
Matteo Scandolo | a6a3aee | 2019-11-26 13:30:14 -0700 | [diff] [blame] | 1485 | ) |
| 1486 | |
| 1487 | var ( |
| 1488 | forward_BBSim_Version_0 = runtime.ForwardResponseMessage |
| 1489 | |
| 1490 | forward_BBSim_GetOlt_0 = runtime.ForwardResponseMessage |
| 1491 | |
| 1492 | forward_BBSim_GetOlt_1 = runtime.ForwardResponseMessage |
| 1493 | |
Matteo Scandolo | a6a3aee | 2019-11-26 13:30:14 -0700 | [diff] [blame] | 1494 | forward_BBSim_GetONU_0 = runtime.ForwardResponseMessage |
Pragya Arya | 1cbefa4 | 2020-01-13 12:15:29 +0530 | [diff] [blame] | 1495 | |
Pragya Arya | bd731ec | 2020-02-11 16:38:17 +0530 | [diff] [blame^] | 1496 | forward_BBSim_GetONUs_0 = runtime.ForwardResponseMessage |
| 1497 | |
Pragya Arya | 1cbefa4 | 2020-01-13 12:15:29 +0530 | [diff] [blame] | 1498 | forward_BBSim_ShutdownONU_0 = runtime.ForwardResponseMessage |
| 1499 | |
Pragya Arya | bd731ec | 2020-02-11 16:38:17 +0530 | [diff] [blame^] | 1500 | forward_BBSim_ShutdownAllONUs_0 = runtime.ForwardResponseMessage |
| 1501 | |
| 1502 | forward_BBSim_ShutdownONUsOnPON_0 = runtime.ForwardResponseMessage |
| 1503 | |
Pragya Arya | 1cbefa4 | 2020-01-13 12:15:29 +0530 | [diff] [blame] | 1504 | forward_BBSim_PoweronONU_0 = runtime.ForwardResponseMessage |
Pragya Arya | 694ece0 | 2020-02-07 13:03:47 +0530 | [diff] [blame] | 1505 | |
Pragya Arya | bd731ec | 2020-02-11 16:38:17 +0530 | [diff] [blame^] | 1506 | forward_BBSim_PoweronAllONUs_0 = runtime.ForwardResponseMessage |
| 1507 | |
| 1508 | forward_BBSim_PoweronONUsOnPON_0 = runtime.ForwardResponseMessage |
| 1509 | |
Anand S Katti | 86552f9 | 2020-03-03 21:56:32 +0530 | [diff] [blame] | 1510 | forward_BBSim_SetOnuAlarmIndication_0 = runtime.ForwardResponseMessage |
| 1511 | |
| 1512 | forward_BBSim_SetOltAlarmIndication_0 = runtime.ForwardResponseMessage |
Anand S Katti | 0954135 | 2020-01-29 15:54:01 +0530 | [diff] [blame] | 1513 | |
Pragya Arya | 8bdb453 | 2020-03-02 17:08:09 +0530 | [diff] [blame] | 1514 | forward_BBSim_GetFlows_0 = runtime.ForwardResponseMessage |
| 1515 | |
| 1516 | forward_BBSim_GetFlows_1 = runtime.ForwardResponseMessage |
| 1517 | |
Anand S Katti | 0954135 | 2020-01-29 15:54:01 +0530 | [diff] [blame] | 1518 | forward_BBSim_GetOnuTrafficSchedulers_0 = runtime.ForwardResponseMessage |
Matteo Scandolo | a6a3aee | 2019-11-26 13:30:14 -0700 | [diff] [blame] | 1519 | ) |