| 1 |
// Copyright 2026 Google LLC |
| 2 |
// |
| 3 |
// Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 |
// you may not use this file except in compliance with the License. |
| 5 |
// You may obtain a copy of the License at |
| 6 |
// |
| 7 |
// http://www.apache.org/licenses/LICENSE-2.0 |
| 8 |
// |
| 9 |
// Unless required by applicable law or agreed to in writing, software |
| 10 |
// distributed under the License is distributed on an "AS IS" BASIS, |
| 11 |
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 |
// See the License for the specific language governing permissions and |
| 13 |
// limitations under the License. |
| 14 |
|
| 15 |
// Code generated by protoc-gen-go. DO NOT EDIT. |
| 16 |
// versions: |
| 17 |
// protoc-gen-go v1.26.0 |
| 18 |
// protoc v4.24.4 |
| 19 |
// source: google/api/routing.proto |
| 20 |
|
| 21 |
package annotations |
| 22 |
|
| 23 |
import ( |
| 24 |
reflect "reflect" |
| 25 |
sync "sync" |
| 26 |
|
| 27 |
protoreflect "google.golang.org/protobuf/reflect/protoreflect" |
| 28 |
protoimpl "google.golang.org/protobuf/runtime/protoimpl" |
| 29 |
descriptorpb "google.golang.org/protobuf/types/descriptorpb" |
| 30 |
) |
| 31 |
|
| 32 |
const ( |
| 33 |
// Verify that this generated code is sufficiently up-to-date. |
| 34 |
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) |
| 35 |
// Verify that runtime/protoimpl is sufficiently up-to-date. |
| 36 |
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) |
| 37 |
) |
| 38 |
|
| 39 |
// Specifies the routing information that should be sent along with the request |
| 40 |
// in the form of routing header. |
| 41 |
// **NOTE:** All service configuration rules follow the "last one wins" order. |
| 42 |
// |
| 43 |
// The examples below will apply to an RPC which has the following request type: |
| 44 |
// |
| 45 |
// Message Definition: |
| 46 |
// |
| 47 |
// message Request { |
| 48 |
// // The name of the Table |
| 49 |
// // Values can be of the following formats: |
| 50 |
// // - `projects/<project>/tables/<table>` |
| 51 |
// // - `projects/<project>/instances/<instance>/tables/<table>` |
| 52 |
// // - `region/<region>/zones/<zone>/tables/<table>` |
| 53 |
// string table_name = 1; |
| 54 |
// |
| 55 |
// // This value specifies routing for replication. |
| 56 |
// // It can be in the following formats: |
| 57 |
// // - `profiles/<profile_id>` |
| 58 |
// // - a legacy `profile_id` that can be any string |
| 59 |
// string app_profile_id = 2; |
| 60 |
// } |
| 61 |
// |
| 62 |
// Example message: |
| 63 |
// |
| 64 |
// { |
| 65 |
// table_name: projects/proj_foo/instances/instance_bar/table/table_baz, |
| 66 |
// app_profile_id: profiles/prof_qux |
| 67 |
// } |
| 68 |
// |
| 69 |
// The routing header consists of one or multiple key-value pairs. The order of |
| 70 |
// the key-value pairs is undefined, the order of the `routing_parameters` in |
| 71 |
// the `RoutingRule` only matters for the evaluation order of the path |
| 72 |
// templates when `field` is the same. See the examples below for more details. |
| 73 |
// |
| 74 |
// Every key and value in the routing header must be percent-encoded, |
| 75 |
// and joined together in the following format: `key1=value1&key2=value2`. |
| 76 |
// The examples below skip the percent-encoding for readability. |
| 77 |
// |
| 78 |
// # Example 1 |
| 79 |
// |
| 80 |
// Extracting a field from the request to put into the routing header |
| 81 |
// unchanged, with the key equal to the field name. |
| 82 |
// |
| 83 |
// annotation: |
| 84 |
// |
| 85 |
// option (google.api.routing) = { |
| 86 |
// // Take the `app_profile_id`. |
| 87 |
// routing_parameters { |
| 88 |
// field: "app_profile_id" |
| 89 |
// } |
| 90 |
// }; |
| 91 |
// |
| 92 |
// result: |
| 93 |
// |
| 94 |
// x-goog-request-params: app_profile_id=profiles/prof_qux |
| 95 |
// |
| 96 |
// # Example 2 |
| 97 |
// |
| 98 |
// Extracting a field from the request to put into the routing header |
| 99 |
// unchanged, with the key different from the field name. |
| 100 |
// |
| 101 |
// annotation: |
| 102 |
// |
| 103 |
// option (google.api.routing) = { |
| 104 |
// // Take the `app_profile_id`, but name it `routing_id` in the header. |
| 105 |
// routing_parameters { |
| 106 |
// field: "app_profile_id" |
| 107 |
// path_template: "{routing_id=**}" |
| 108 |
// } |
| 109 |
// }; |
| 110 |
// |
| 111 |
// result: |
| 112 |
// |
| 113 |
// x-goog-request-params: routing_id=profiles/prof_qux |
| 114 |
// |
| 115 |
// # Example 3 |
| 116 |
// |
| 117 |
// Extracting a field from the request to put into the routing |
| 118 |
// header, while matching a path template syntax on the field's value. |
| 119 |
// |
| 120 |
// NB: it is more useful to send nothing than to send garbage for the purpose |
| 121 |
// of dynamic routing, since garbage pollutes cache. Thus the matching. |
| 122 |
// |
| 123 |
// # Sub-example 3a |
| 124 |
// |
| 125 |
// The field matches the template. |
| 126 |
// |
| 127 |
// annotation: |
| 128 |
// |
| 129 |
// option (google.api.routing) = { |
| 130 |
// // Take the `table_name`, if it's well-formed (with project-based |
| 131 |
// // syntax). |
| 132 |
// routing_parameters { |
| 133 |
// field: "table_name" |
| 134 |
// path_template: "{table_name=projects/*/instances/*/**}" |
| 135 |
// } |
| 136 |
// }; |
| 137 |
// |
| 138 |
// result: |
| 139 |
// |
| 140 |
// x-goog-request-params: |
| 141 |
// table_name=projects/proj_foo/instances/instance_bar/table/table_baz |
| 142 |
// |
| 143 |
// # Sub-example 3b |
| 144 |
// |
| 145 |
// The field does not match the template. |
| 146 |
// |
| 147 |
// annotation: |
| 148 |
// |
| 149 |
// option (google.api.routing) = { |
| 150 |
// // Take the `table_name`, if it's well-formed (with region-based |
| 151 |
// // syntax). |
| 152 |
// routing_parameters { |
| 153 |
// field: "table_name" |
| 154 |
// path_template: "{table_name=regions/*/zones/*/**}" |
| 155 |
// } |
| 156 |
// }; |
| 157 |
// |
| 158 |
// result: |
| 159 |
// |
| 160 |
// <no routing header will be sent> |
| 161 |
// |
| 162 |
// # Sub-example 3c |
| 163 |
// |
| 164 |
// Multiple alternative conflictingly named path templates are |
| 165 |
// specified. The one that matches is used to construct the header. |
| 166 |
// |
| 167 |
// annotation: |
| 168 |
// |
| 169 |
// option (google.api.routing) = { |
| 170 |
// // Take the `table_name`, if it's well-formed, whether |
| 171 |
// // using the region- or projects-based syntax. |
| 172 |
// |
| 173 |
// routing_parameters { |
| 174 |
// field: "table_name" |
| 175 |
// path_template: "{table_name=regions/*/zones/*/**}" |
| 176 |
// } |
| 177 |
// routing_parameters { |
| 178 |
// field: "table_name" |
| 179 |
// path_template: "{table_name=projects/*/instances/*/**}" |
| 180 |
// } |
| 181 |
// }; |
| 182 |
// |
| 183 |
// result: |
| 184 |
// |
| 185 |
// x-goog-request-params: |
| 186 |
// table_name=projects/proj_foo/instances/instance_bar/table/table_baz |
| 187 |
// |
| 188 |
// # Example 4 |
| 189 |
// |
| 190 |
// Extracting a single routing header key-value pair by matching a |
| 191 |
// template syntax on (a part of) a single request field. |
| 192 |
// |
| 193 |
// annotation: |
| 194 |
// |
| 195 |
// option (google.api.routing) = { |
| 196 |
// // Take just the project id from the `table_name` field. |
| 197 |
// routing_parameters { |
| 198 |
// field: "table_name" |
| 199 |
// path_template: "{routing_id=projects/*}/**" |
| 200 |
// } |
| 201 |
// }; |
| 202 |
// |
| 203 |
// result: |
| 204 |
// |
| 205 |
// x-goog-request-params: routing_id=projects/proj_foo |
| 206 |
// |
| 207 |
// # Example 5 |
| 208 |
// |
| 209 |
// Extracting a single routing header key-value pair by matching |
| 210 |
// several conflictingly named path templates on (parts of) a single request |
| 211 |
// field. The last template to match "wins" the conflict. |
| 212 |
// |
| 213 |
// annotation: |
| 214 |
// |
| 215 |
// option (google.api.routing) = { |
| 216 |
// // If the `table_name` does not have instances information, |
| 217 |
// // take just the project id for routing. |
| 218 |
// // Otherwise take project + instance. |
| 219 |
// |
| 220 |
// routing_parameters { |
| 221 |
// field: "table_name" |
| 222 |
// path_template: "{routing_id=projects/*}/**" |
| 223 |
// } |
| 224 |
// routing_parameters { |
| 225 |
// field: "table_name" |
| 226 |
// path_template: "{routing_id=projects/*/instances/*}/**" |
| 227 |
// } |
| 228 |
// }; |
| 229 |
// |
| 230 |
// result: |
| 231 |
// |
| 232 |
// x-goog-request-params: |
| 233 |
// routing_id=projects/proj_foo/instances/instance_bar |
| 234 |
// |
| 235 |
// # Example 6 |
| 236 |
// |
| 237 |
// Extracting multiple routing header key-value pairs by matching |
| 238 |
// several non-conflicting path templates on (parts of) a single request field. |
| 239 |
// |
| 240 |
// # Sub-example 6a |
| 241 |
// |
| 242 |
// Make the templates strict, so that if the `table_name` does not |
| 243 |
// have an instance information, nothing is sent. |
| 244 |
// |
| 245 |
// annotation: |
| 246 |
// |
| 247 |
// option (google.api.routing) = { |
| 248 |
// // The routing code needs two keys instead of one composite |
| 249 |
// // but works only for the tables with the "project-instance" name |
| 250 |
// // syntax. |
| 251 |
// |
| 252 |
// routing_parameters { |
| 253 |
// field: "table_name" |
| 254 |
// path_template: "{project_id=projects/*}/instances/*/**" |
| 255 |
// } |
| 256 |
// routing_parameters { |
| 257 |
// field: "table_name" |
| 258 |
// path_template: "projects/*/{instance_id=instances/*}/**" |
| 259 |
// } |
| 260 |
// }; |
| 261 |
// |
| 262 |
// result: |
| 263 |
// |
| 264 |
// x-goog-request-params: |
| 265 |
// project_id=projects/proj_foo&instance_id=instances/instance_bar |
| 266 |
// |
| 267 |
// # Sub-example 6b |
| 268 |
// |
| 269 |
// Make the templates loose, so that if the `table_name` does not |
| 270 |
// have an instance information, just the project id part is sent. |
| 271 |
// |
| 272 |
// annotation: |
| 273 |
// |
| 274 |
// option (google.api.routing) = { |
| 275 |
// // The routing code wants two keys instead of one composite |
| 276 |
// // but will work with just the `project_id` for tables without |
| 277 |
// // an instance in the `table_name`. |
| 278 |
// |
| 279 |
// routing_parameters { |
| 280 |
// field: "table_name" |
| 281 |
// path_template: "{project_id=projects/*}/**" |
| 282 |
// } |
| 283 |
// routing_parameters { |
| 284 |
// field: "table_name" |
| 285 |
// path_template: "projects/*/{instance_id=instances/*}/**" |
| 286 |
// } |
| 287 |
// }; |
| 288 |
// |
| 289 |
// result (is the same as 6a for our example message because it has the instance |
| 290 |
// information): |
| 291 |
// |
| 292 |
// x-goog-request-params: |
| 293 |
// project_id=projects/proj_foo&instance_id=instances/instance_bar |
| 294 |
// |
| 295 |
// # Example 7 |
| 296 |
// |
| 297 |
// Extracting multiple routing header key-value pairs by matching |
| 298 |
// several path templates on multiple request fields. |
| 299 |
// |
| 300 |
// NB: note that here there is no way to specify sending nothing if one of the |
| 301 |
// fields does not match its template. E.g. if the `table_name` is in the wrong |
| 302 |
// format, the `project_id` will not be sent, but the `routing_id` will be. |
| 303 |
// The backend routing code has to be aware of that and be prepared to not |
| 304 |
// receive a full complement of keys if it expects multiple. |
| 305 |
// |
| 306 |
// annotation: |
| 307 |
// |
| 308 |
// option (google.api.routing) = { |
| 309 |
// // The routing needs both `project_id` and `routing_id` |
| 310 |
// // (from the `app_profile_id` field) for routing. |
| 311 |
// |
| 312 |
// routing_parameters { |
| 313 |
// field: "table_name" |
| 314 |
// path_template: "{project_id=projects/*}/**" |
| 315 |
// } |
| 316 |
// routing_parameters { |
| 317 |
// field: "app_profile_id" |
| 318 |
// path_template: "{routing_id=**}" |
| 319 |
// } |
| 320 |
// }; |
| 321 |
// |
| 322 |
// result: |
| 323 |
// |
| 324 |
// x-goog-request-params: |
| 325 |
// project_id=projects/proj_foo&routing_id=profiles/prof_qux |
| 326 |
// |
| 327 |
// # Example 8 |
| 328 |
// |
| 329 |
// Extracting a single routing header key-value pair by matching |
| 330 |
// several conflictingly named path templates on several request fields. The |
| 331 |
// last template to match "wins" the conflict. |
| 332 |
// |
| 333 |
// annotation: |
| 334 |
// |
| 335 |
// option (google.api.routing) = { |
| 336 |
// // The `routing_id` can be a project id or a region id depending on |
| 337 |
// // the table name format, but only if the `app_profile_id` is not set. |
| 338 |
// // If `app_profile_id` is set it should be used instead. |
| 339 |
// |
| 340 |
// routing_parameters { |
| 341 |
// field: "table_name" |
| 342 |
// path_template: "{routing_id=projects/*}/**" |
| 343 |
// } |
| 344 |
// routing_parameters { |
| 345 |
// field: "table_name" |
| 346 |
// path_template: "{routing_id=regions/*}/**" |
| 347 |
// } |
| 348 |
// routing_parameters { |
| 349 |
// field: "app_profile_id" |
| 350 |
// path_template: "{routing_id=**}" |
| 351 |
// } |
| 352 |
// }; |
| 353 |
// |
| 354 |
// result: |
| 355 |
// |
| 356 |
// x-goog-request-params: routing_id=profiles/prof_qux |
| 357 |
// |
| 358 |
// # Example 9 |
| 359 |
// |
| 360 |
// Bringing it all together. |
| 361 |
// |
| 362 |
// annotation: |
| 363 |
// |
| 364 |
// option (google.api.routing) = { |
| 365 |
// // For routing both `table_location` and a `routing_id` are needed. |
| 366 |
// // |
| 367 |
// // table_location can be either an instance id or a region+zone id. |
| 368 |
// // |
| 369 |
// // For `routing_id`, take the value of `app_profile_id` |
| 370 |
// // - If it's in the format `profiles/<profile_id>`, send |
| 371 |
// // just the `<profile_id>` part. |
| 372 |
// // - If it's any other literal, send it as is. |
| 373 |
// // If the `app_profile_id` is empty, and the `table_name` starts with |
| 374 |
// // the project_id, send that instead. |
| 375 |
// |
| 376 |
// routing_parameters { |
| 377 |
// field: "table_name" |
| 378 |
// path_template: "projects/*/{table_location=instances/*}/tables/*" |
| 379 |
// } |
| 380 |
// routing_parameters { |
| 381 |
// field: "table_name" |
| 382 |
// path_template: "{table_location=regions/*/zones/*}/tables/*" |
| 383 |
// } |
| 384 |
// routing_parameters { |
| 385 |
// field: "table_name" |
| 386 |
// path_template: "{routing_id=projects/*}/**" |
| 387 |
// } |
| 388 |
// routing_parameters { |
| 389 |
// field: "app_profile_id" |
| 390 |
// path_template: "{routing_id=**}" |
| 391 |
// } |
| 392 |
// routing_parameters { |
| 393 |
// field: "app_profile_id" |
| 394 |
// path_template: "profiles/{routing_id=*}" |
| 395 |
// } |
| 396 |
// }; |
| 397 |
// |
| 398 |
// result: |
| 399 |
// |
| 400 |
// x-goog-request-params: |
| 401 |
// table_location=instances/instance_bar&routing_id=prof_qux |
| 402 |
type RoutingRule struct { |
| 403 |
state protoimpl.MessageState |
| 404 |
sizeCache protoimpl.SizeCache |
| 405 |
unknownFields protoimpl.UnknownFields |
| 406 |
|
| 407 |
// A collection of Routing Parameter specifications. |
| 408 |
// **NOTE:** If multiple Routing Parameters describe the same key |
| 409 |
// (via the `path_template` field or via the `field` field when |
| 410 |
// `path_template` is not provided), "last one wins" rule |
| 411 |
// determines which Parameter gets used. |
| 412 |
// See the examples for more details. |
| 413 |
RoutingParameters []*RoutingParameter `protobuf:"bytes,2,rep,name=routing_parameters,json=routingParameters,proto3" json:"routing_parameters,omitempty"` |
| 414 |
} |
| 415 |
|
| 416 |
func (x *RoutingRule) Reset() { |
| 417 |
*x = RoutingRule{} |
| 418 |
if protoimpl.UnsafeEnabled { |
| 419 |
mi := &file_google_api_routing_proto_msgTypes[0] |
| 420 |
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) |
| 421 |
ms.StoreMessageInfo(mi) |
| 422 |
} |
| 423 |
} |
| 424 |
|
| 425 |
func (x *RoutingRule) String() string { |
| 426 |
return protoimpl.X.MessageStringOf(x) |
| 427 |
} |
| 428 |
|
| 429 |
func (*RoutingRule) ProtoMessage() {} |
| 430 |
|
| 431 |
func (x *RoutingRule) ProtoReflect() protoreflect.Message { |
| 432 |
mi := &file_google_api_routing_proto_msgTypes[0] |
| 433 |
if protoimpl.UnsafeEnabled && x != nil { |
| 434 |
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) |
| 435 |
if ms.LoadMessageInfo() == nil { |
| 436 |
ms.StoreMessageInfo(mi) |
| 437 |
} |
| 438 |
return ms |
| 439 |
} |
| 440 |
return mi.MessageOf(x) |
| 441 |
} |
| 442 |
|
| 443 |
// Deprecated: Use RoutingRule.ProtoReflect.Descriptor instead. |
| 444 |
func (*RoutingRule) Descriptor() ([]byte, []int) { |
| 445 |
return file_google_api_routing_proto_rawDescGZIP(), []int{0} |
| 446 |
} |
| 447 |
|
| 448 |
func (x *RoutingRule) GetRoutingParameters() []*RoutingParameter { |
| 449 |
if x != nil { |
| 450 |
return x.RoutingParameters |
| 451 |
} |
| 452 |
return nil |
| 453 |
} |
| 454 |
|
| 455 |
// A projection from an input message to the GRPC or REST header. |
| 456 |
type RoutingParameter struct { |
| 457 |
state protoimpl.MessageState |
| 458 |
sizeCache protoimpl.SizeCache |
| 459 |
unknownFields protoimpl.UnknownFields |
| 460 |
|
| 461 |
// A request field to extract the header key-value pair from. |
| 462 |
Field string `protobuf:"bytes,1,opt,name=field,proto3" json:"field,omitempty"` |
| 463 |
// A pattern matching the key-value field. Optional. |
| 464 |
// If not specified, the whole field specified in the `field` field will be |
| 465 |
// taken as value, and its name used as key. If specified, it MUST contain |
| 466 |
// exactly one named segment (along with any number of unnamed segments) The |
| 467 |
// pattern will be matched over the field specified in the `field` field, then |
| 468 |
// if the match is successful: |
| 469 |
// - the name of the single named segment will be used as a header name, |
| 470 |
// - the match value of the segment will be used as a header value; |
| 471 |
// if the match is NOT successful, nothing will be sent. |
| 472 |
// |
| 473 |
// Example: |
| 474 |
// |
| 475 |
// -- This is a field in the request message |
| 476 |
// | that the header value will be extracted from. |
| 477 |
// | |
| 478 |
// | -- This is the key name in the |
| 479 |
// | | routing header. |
| 480 |
// V | |
| 481 |
// field: "table_name" v |
| 482 |
// path_template: "projects/*/{table_location=instances/*}/tables/*" |
| 483 |
// ^ ^ |
| 484 |
// | | |
| 485 |
// In the {} brackets is the pattern that -- | |
| 486 |
// specifies what to extract from the | |
| 487 |
// field as a value to be sent. | |
| 488 |
// | |
| 489 |
// The string in the field must match the whole pattern -- |
| 490 |
// before brackets, inside brackets, after brackets. |
| 491 |
// |
| 492 |
// When looking at this specific example, we can see that: |
| 493 |
// - A key-value pair with the key `table_location` |
| 494 |
// and the value matching `instances/*` should be added |
| 495 |
// to the x-goog-request-params routing header. |
| 496 |
// - The value is extracted from the request message's `table_name` field |
| 497 |
// if it matches the full pattern specified: |
| 498 |
// `projects/*/instances/*/tables/*`. |
| 499 |
// |
| 500 |
// **NB:** If the `path_template` field is not provided, the key name is |
| 501 |
// equal to the field name, and the whole field should be sent as a value. |
| 502 |
// This makes the pattern for the field and the value functionally equivalent |
| 503 |
// to `**`, and the configuration |
| 504 |
// |
| 505 |
// { |
| 506 |
// field: "table_name" |
| 507 |
// } |
| 508 |
// |
| 509 |
// is a functionally equivalent shorthand to: |
| 510 |
// |
| 511 |
// { |
| 512 |
// field: "table_name" |
| 513 |
// path_template: "{table_name=**}" |
| 514 |
// } |
| 515 |
// |
| 516 |
// See Example 1 for more details. |
| 517 |
PathTemplate string `protobuf:"bytes,2,opt,name=path_template,json=pathTemplate,proto3" json:"path_template,omitempty"` |
| 518 |
} |
| 519 |
|
| 520 |
func (x *RoutingParameter) Reset() { |
| 521 |
*x = RoutingParameter{} |
| 522 |
if protoimpl.UnsafeEnabled { |
| 523 |
mi := &file_google_api_routing_proto_msgTypes[1] |
| 524 |
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) |
| 525 |
ms.StoreMessageInfo(mi) |
| 526 |
} |
| 527 |
} |
| 528 |
|
| 529 |
func (x *RoutingParameter) String() string { |
| 530 |
return protoimpl.X.MessageStringOf(x) |
| 531 |
} |
| 532 |
|
| 533 |
func (*RoutingParameter) ProtoMessage() {} |
| 534 |
|
| 535 |
func (x *RoutingParameter) ProtoReflect() protoreflect.Message { |
| 536 |
mi := &file_google_api_routing_proto_msgTypes[1] |
| 537 |
if protoimpl.UnsafeEnabled && x != nil { |
| 538 |
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) |
| 539 |
if ms.LoadMessageInfo() == nil { |
| 540 |
ms.StoreMessageInfo(mi) |
| 541 |
} |
| 542 |
return ms |
| 543 |
} |
| 544 |
return mi.MessageOf(x) |
| 545 |
} |
| 546 |
|
| 547 |
// Deprecated: Use RoutingParameter.ProtoReflect.Descriptor instead. |
| 548 |
func (*RoutingParameter) Descriptor() ([]byte, []int) { |
| 549 |
return file_google_api_routing_proto_rawDescGZIP(), []int{1} |
| 550 |
} |
| 551 |
|
| 552 |
func (x *RoutingParameter) GetField() string { |
| 553 |
if x != nil { |
| 554 |
return x.Field |
| 555 |
} |
| 556 |
return "" |
| 557 |
} |
| 558 |
|
| 559 |
func (x *RoutingParameter) GetPathTemplate() string { |
| 560 |
if x != nil { |
| 561 |
return x.PathTemplate |
| 562 |
} |
| 563 |
return "" |
| 564 |
} |
| 565 |
|
| 566 |
var file_google_api_routing_proto_extTypes = []protoimpl.ExtensionInfo{ |
| 567 |
{ |
| 568 |
ExtendedType: (*descriptorpb.MethodOptions)(nil), |
| 569 |
ExtensionType: (*RoutingRule)(nil), |
| 570 |
Field: 72295729, |
| 571 |
Name: "google.api.routing", |
| 572 |
Tag: "bytes,72295729,opt,name=routing", |
| 573 |
Filename: "google/api/routing.proto", |
| 574 |
}, |
| 575 |
} |
| 576 |
|
| 577 |
// Extension fields to descriptorpb.MethodOptions. |
| 578 |
var ( |
| 579 |
// See RoutingRule. |
| 580 |
// |
| 581 |
// optional google.api.RoutingRule routing = 72295729; |
| 582 |
E_Routing = &file_google_api_routing_proto_extTypes[0] |
| 583 |
) |
| 584 |
|
| 585 |
var File_google_api_routing_proto protoreflect.FileDescriptor |
| 586 |
|
| 587 |
var file_google_api_routing_proto_rawDesc = []byte{ |
| 588 |
0x0a, 0x18, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x72, 0x6f, 0x75, |
| 589 |
0x74, 0x69, 0x6e, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0a, 0x67, 0x6f, 0x6f, 0x67, |
| 590 |
0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x1a, 0x20, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, |
| 591 |
0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, |
| 592 |
0x6f, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x5a, 0x0a, 0x0b, 0x52, 0x6f, 0x75, 0x74, |
| 593 |
0x69, 0x6e, 0x67, 0x52, 0x75, 0x6c, 0x65, 0x12, 0x4b, 0x0a, 0x12, 0x72, 0x6f, 0x75, 0x74, 0x69, |
| 594 |
0x6e, 0x67, 0x5f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x65, 0x74, 0x65, 0x72, 0x73, 0x18, 0x02, 0x20, |
| 595 |
0x03, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, |
| 596 |
0x2e, 0x52, 0x6f, 0x75, 0x74, 0x69, 0x6e, 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x65, 0x74, 0x65, |
| 597 |
0x72, 0x52, 0x11, 0x72, 0x6f, 0x75, 0x74, 0x69, 0x6e, 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x65, |
| 598 |
0x74, 0x65, 0x72, 0x73, 0x22, 0x4d, 0x0a, 0x10, 0x52, 0x6f, 0x75, 0x74, 0x69, 0x6e, 0x67, 0x50, |
| 599 |
0x61, 0x72, 0x61, 0x6d, 0x65, 0x74, 0x65, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x66, 0x69, 0x65, 0x6c, |
| 600 |
0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x12, 0x23, |
| 601 |
0x0a, 0x0d, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x74, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x18, |
| 602 |
0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x70, 0x61, 0x74, 0x68, 0x54, 0x65, 0x6d, 0x70, 0x6c, |
| 603 |
0x61, 0x74, 0x65, 0x3a, 0x54, 0x0a, 0x07, 0x72, 0x6f, 0x75, 0x74, 0x69, 0x6e, 0x67, 0x12, 0x1e, |
| 604 |
0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, |
| 605 |
0x2e, 0x4d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0xb1, |
| 606 |
0xca, 0xbc, 0x22, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, |
| 607 |
0x2e, 0x61, 0x70, 0x69, 0x2e, 0x52, 0x6f, 0x75, 0x74, 0x69, 0x6e, 0x67, 0x52, 0x75, 0x6c, 0x65, |
| 608 |
0x52, 0x07, 0x72, 0x6f, 0x75, 0x74, 0x69, 0x6e, 0x67, 0x42, 0x6a, 0x0a, 0x0e, 0x63, 0x6f, 0x6d, |
| 609 |
0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x42, 0x0c, 0x52, 0x6f, 0x75, |
| 610 |
0x74, 0x69, 0x6e, 0x67, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x41, 0x67, 0x6f, 0x6f, |
| 611 |
0x67, 0x6c, 0x65, 0x2e, 0x67, 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x67, |
| 612 |
0x65, 0x6e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x61, 0x70, |
| 613 |
0x69, 0x73, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, |
| 614 |
0x6e, 0x73, 0x3b, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0xa2, 0x02, |
| 615 |
0x04, 0x47, 0x41, 0x50, 0x49, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, |
| 616 |
} |
| 617 |
|
| 618 |
var ( |
| 619 |
file_google_api_routing_proto_rawDescOnce sync.Once |
| 620 |
file_google_api_routing_proto_rawDescData = file_google_api_routing_proto_rawDesc |
| 621 |
) |
| 622 |
|
| 623 |
func file_google_api_routing_proto_rawDescGZIP() []byte { |
| 624 |
file_google_api_routing_proto_rawDescOnce.Do(func() { |
| 625 |
file_google_api_routing_proto_rawDescData = protoimpl.X.CompressGZIP(file_google_api_routing_proto_rawDescData) |
| 626 |
}) |
| 627 |
return file_google_api_routing_proto_rawDescData |
| 628 |
} |
| 629 |
|
| 630 |
var file_google_api_routing_proto_msgTypes = make([]protoimpl.MessageInfo, 2) |
| 631 |
var file_google_api_routing_proto_goTypes = []interface{}{ |
| 632 |
(*RoutingRule)(nil), // 0: google.api.RoutingRule |
| 633 |
(*RoutingParameter)(nil), // 1: google.api.RoutingParameter |
| 634 |
(*descriptorpb.MethodOptions)(nil), // 2: google.protobuf.MethodOptions |
| 635 |
} |
| 636 |
var file_google_api_routing_proto_depIdxs = []int32{ |
| 637 |
1, // 0: google.api.RoutingRule.routing_parameters:type_name -> google.api.RoutingParameter |
| 638 |
2, // 1: google.api.routing:extendee -> google.protobuf.MethodOptions |
| 639 |
0, // 2: google.api.routing:type_name -> google.api.RoutingRule |
| 640 |
3, // [3:3] is the sub-list for method output_type |
| 641 |
3, // [3:3] is the sub-list for method input_type |
| 642 |
2, // [2:3] is the sub-list for extension type_name |
| 643 |
1, // [1:2] is the sub-list for extension extendee |
| 644 |
0, // [0:1] is the sub-list for field type_name |
| 645 |
} |
| 646 |
|
| 647 |
func init() { file_google_api_routing_proto_init() } |
| 648 |
func file_google_api_routing_proto_init() { |
| 649 |
if File_google_api_routing_proto != nil { |
| 650 |
return |
| 651 |
} |
| 652 |
if !protoimpl.UnsafeEnabled { |
| 653 |
file_google_api_routing_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { |
| 654 |
switch v := v.(*RoutingRule); i { |
| 655 |
case 0: |
| 656 |
return &v.state |
| 657 |
case 1: |
| 658 |
return &v.sizeCache |
| 659 |
case 2: |
| 660 |
return &v.unknownFields |
| 661 |
default: |
| 662 |
return nil |
| 663 |
} |
| 664 |
} |
| 665 |
file_google_api_routing_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { |
| 666 |
switch v := v.(*RoutingParameter); i { |
| 667 |
case 0: |
| 668 |
return &v.state |
| 669 |
case 1: |
| 670 |
return &v.sizeCache |
| 671 |
case 2: |
| 672 |
return &v.unknownFields |
| 673 |
default: |
| 674 |
return nil |
| 675 |
} |
| 676 |
} |
| 677 |
} |
| 678 |
type x struct{} |
| 679 |
out := protoimpl.TypeBuilder{ |
| 680 |
File: protoimpl.DescBuilder{ |
| 681 |
GoPackagePath: reflect.TypeOf(x{}).PkgPath(), |
| 682 |
RawDescriptor: file_google_api_routing_proto_rawDesc, |
| 683 |
NumEnums: 0, |
| 684 |
NumMessages: 2, |
| 685 |
NumExtensions: 1, |
| 686 |
NumServices: 0, |
| 687 |
}, |
| 688 |
GoTypes: file_google_api_routing_proto_goTypes, |
| 689 |
DependencyIndexes: file_google_api_routing_proto_depIdxs, |
| 690 |
MessageInfos: file_google_api_routing_proto_msgTypes, |
| 691 |
ExtensionInfos: file_google_api_routing_proto_extTypes, |
| 692 |
}.Build() |
| 693 |
File_google_api_routing_proto = out.File |
| 694 |
file_google_api_routing_proto_rawDesc = nil |
| 695 |
file_google_api_routing_proto_goTypes = nil |
| 696 |
file_google_api_routing_proto_depIdxs = nil |
| 697 |
} |