| 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/field_behavior.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 |
// An indicator of the behavior of a given field (for example, that a field |
| 40 |
// is required in requests, or given as output but ignored as input). |
| 41 |
// This **does not** change the behavior in protocol buffers itself; it only |
| 42 |
// denotes the behavior and may affect how API tooling handles the field. |
| 43 |
// |
| 44 |
// Note: This enum **may** receive new values in the future. |
| 45 |
type FieldBehavior int32 |
| 46 |
|
| 47 |
const ( |
| 48 |
// Conventional default for enums. Do not use this. |
| 49 |
FieldBehavior_FIELD_BEHAVIOR_UNSPECIFIED FieldBehavior = 0 |
| 50 |
// Specifically denotes a field as optional. |
| 51 |
// While all fields in protocol buffers are optional, this may be specified |
| 52 |
// for emphasis if appropriate. |
| 53 |
FieldBehavior_OPTIONAL FieldBehavior = 1 |
| 54 |
// Denotes a field as required. |
| 55 |
// This indicates that the field **must** be provided as part of the request, |
| 56 |
// and failure to do so will cause an error (usually `INVALID_ARGUMENT`). |
| 57 |
FieldBehavior_REQUIRED FieldBehavior = 2 |
| 58 |
// Denotes a field as output only. |
| 59 |
// This indicates that the field is provided in responses, but including the |
| 60 |
// field in a request does nothing (the server *must* ignore it and |
| 61 |
// *must not* throw an error as a result of the field's presence). |
| 62 |
FieldBehavior_OUTPUT_ONLY FieldBehavior = 3 |
| 63 |
// Denotes a field as input only. |
| 64 |
// This indicates that the field is provided in requests, and the |
| 65 |
// corresponding field is not included in output. |
| 66 |
FieldBehavior_INPUT_ONLY FieldBehavior = 4 |
| 67 |
// Denotes a field as immutable. |
| 68 |
// This indicates that the field may be set once in a request to create a |
| 69 |
// resource, but may not be changed thereafter. |
| 70 |
FieldBehavior_IMMUTABLE FieldBehavior = 5 |
| 71 |
// Denotes that a (repeated) field is an unordered list. |
| 72 |
// This indicates that the service may provide the elements of the list |
| 73 |
// in any arbitrary order, rather than the order the user originally |
| 74 |
// provided. Additionally, the list's order may or may not be stable. |
| 75 |
FieldBehavior_UNORDERED_LIST FieldBehavior = 6 |
| 76 |
// Denotes that this field returns a non-empty default value if not set. |
| 77 |
// This indicates that if the user provides the empty value in a request, |
| 78 |
// a non-empty value will be returned. The user will not be aware of what |
| 79 |
// non-empty value to expect. |
| 80 |
FieldBehavior_NON_EMPTY_DEFAULT FieldBehavior = 7 |
| 81 |
// Denotes that the field in a resource (a message annotated with |
| 82 |
// google.api.resource) is used in the resource name to uniquely identify the |
| 83 |
// resource. For AIP-compliant APIs, this should only be applied to the |
| 84 |
// `name` field on the resource. |
| 85 |
// |
| 86 |
// This behavior should not be applied to references to other resources within |
| 87 |
// the message. |
| 88 |
// |
| 89 |
// The identifier field of resources often have different field behavior |
| 90 |
// depending on the request it is embedded in (e.g. for Create methods name |
| 91 |
// is optional and unused, while for Update methods it is required). Instead |
| 92 |
// of method-specific annotations, only `IDENTIFIER` is required. |
| 93 |
FieldBehavior_IDENTIFIER FieldBehavior = 8 |
| 94 |
) |
| 95 |
|
| 96 |
// Enum value maps for FieldBehavior. |
| 97 |
var ( |
| 98 |
FieldBehavior_name = map[int32]string{ |
| 99 |
0: "FIELD_BEHAVIOR_UNSPECIFIED", |
| 100 |
1: "OPTIONAL", |
| 101 |
2: "REQUIRED", |
| 102 |
3: "OUTPUT_ONLY", |
| 103 |
4: "INPUT_ONLY", |
| 104 |
5: "IMMUTABLE", |
| 105 |
6: "UNORDERED_LIST", |
| 106 |
7: "NON_EMPTY_DEFAULT", |
| 107 |
8: "IDENTIFIER", |
| 108 |
} |
| 109 |
FieldBehavior_value = map[string]int32{ |
| 110 |
"FIELD_BEHAVIOR_UNSPECIFIED": 0, |
| 111 |
"OPTIONAL": 1, |
| 112 |
"REQUIRED": 2, |
| 113 |
"OUTPUT_ONLY": 3, |
| 114 |
"INPUT_ONLY": 4, |
| 115 |
"IMMUTABLE": 5, |
| 116 |
"UNORDERED_LIST": 6, |
| 117 |
"NON_EMPTY_DEFAULT": 7, |
| 118 |
"IDENTIFIER": 8, |
| 119 |
} |
| 120 |
) |
| 121 |
|
| 122 |
func (x FieldBehavior) Enum() *FieldBehavior { |
| 123 |
p := new(FieldBehavior) |
| 124 |
*p = x |
| 125 |
return p |
| 126 |
} |
| 127 |
|
| 128 |
func (x FieldBehavior) String() string { |
| 129 |
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) |
| 130 |
} |
| 131 |
|
| 132 |
func (FieldBehavior) Descriptor() protoreflect.EnumDescriptor { |
| 133 |
return file_google_api_field_behavior_proto_enumTypes[0].Descriptor() |
| 134 |
} |
| 135 |
|
| 136 |
func (FieldBehavior) Type() protoreflect.EnumType { |
| 137 |
return &file_google_api_field_behavior_proto_enumTypes[0] |
| 138 |
} |
| 139 |
|
| 140 |
func (x FieldBehavior) Number() protoreflect.EnumNumber { |
| 141 |
return protoreflect.EnumNumber(x) |
| 142 |
} |
| 143 |
|
| 144 |
// Deprecated: Use FieldBehavior.Descriptor instead. |
| 145 |
func (FieldBehavior) EnumDescriptor() ([]byte, []int) { |
| 146 |
return file_google_api_field_behavior_proto_rawDescGZIP(), []int{0} |
| 147 |
} |
| 148 |
|
| 149 |
var file_google_api_field_behavior_proto_extTypes = []protoimpl.ExtensionInfo{ |
| 150 |
{ |
| 151 |
ExtendedType: (*descriptorpb.FieldOptions)(nil), |
| 152 |
ExtensionType: ([]FieldBehavior)(nil), |
| 153 |
Field: 1052, |
| 154 |
Name: "google.api.field_behavior", |
| 155 |
Tag: "varint,1052,rep,name=field_behavior,enum=google.api.FieldBehavior", |
| 156 |
Filename: "google/api/field_behavior.proto", |
| 157 |
}, |
| 158 |
} |
| 159 |
|
| 160 |
// Extension fields to descriptorpb.FieldOptions. |
| 161 |
var ( |
| 162 |
// A designation of a specific field behavior (required, output only, etc.) |
| 163 |
// in protobuf messages. |
| 164 |
// |
| 165 |
// Examples: |
| 166 |
// |
| 167 |
// string name = 1 [(google.api.field_behavior) = REQUIRED]; |
| 168 |
// State state = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; |
| 169 |
// google.protobuf.Duration ttl = 1 |
| 170 |
// [(google.api.field_behavior) = INPUT_ONLY]; |
| 171 |
// google.protobuf.Timestamp expire_time = 1 |
| 172 |
// [(google.api.field_behavior) = OUTPUT_ONLY, |
| 173 |
// (google.api.field_behavior) = IMMUTABLE]; |
| 174 |
// |
| 175 |
// repeated google.api.FieldBehavior field_behavior = 1052; |
| 176 |
E_FieldBehavior = &file_google_api_field_behavior_proto_extTypes[0] |
| 177 |
) |
| 178 |
|
| 179 |
var File_google_api_field_behavior_proto protoreflect.FileDescriptor |
| 180 |
|
| 181 |
var file_google_api_field_behavior_proto_rawDesc = []byte{ |
| 182 |
0x0a, 0x1f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x66, 0x69, 0x65, |
| 183 |
0x6c, 0x64, 0x5f, 0x62, 0x65, 0x68, 0x61, 0x76, 0x69, 0x6f, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, |
| 184 |
0x6f, 0x12, 0x0a, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x1a, 0x20, 0x67, |
| 185 |
0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x64, |
| 186 |
0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2a, |
| 187 |
0xb6, 0x01, 0x0a, 0x0d, 0x46, 0x69, 0x65, 0x6c, 0x64, 0x42, 0x65, 0x68, 0x61, 0x76, 0x69, 0x6f, |
| 188 |
0x72, 0x12, 0x1e, 0x0a, 0x1a, 0x46, 0x49, 0x45, 0x4c, 0x44, 0x5f, 0x42, 0x45, 0x48, 0x41, 0x56, |
| 189 |
0x49, 0x4f, 0x52, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, |
| 190 |
0x00, 0x12, 0x0c, 0x0a, 0x08, 0x4f, 0x50, 0x54, 0x49, 0x4f, 0x4e, 0x41, 0x4c, 0x10, 0x01, 0x12, |
| 191 |
0x0c, 0x0a, 0x08, 0x52, 0x45, 0x51, 0x55, 0x49, 0x52, 0x45, 0x44, 0x10, 0x02, 0x12, 0x0f, 0x0a, |
| 192 |
0x0b, 0x4f, 0x55, 0x54, 0x50, 0x55, 0x54, 0x5f, 0x4f, 0x4e, 0x4c, 0x59, 0x10, 0x03, 0x12, 0x0e, |
| 193 |
0x0a, 0x0a, 0x49, 0x4e, 0x50, 0x55, 0x54, 0x5f, 0x4f, 0x4e, 0x4c, 0x59, 0x10, 0x04, 0x12, 0x0d, |
| 194 |
0x0a, 0x09, 0x49, 0x4d, 0x4d, 0x55, 0x54, 0x41, 0x42, 0x4c, 0x45, 0x10, 0x05, 0x12, 0x12, 0x0a, |
| 195 |
0x0e, 0x55, 0x4e, 0x4f, 0x52, 0x44, 0x45, 0x52, 0x45, 0x44, 0x5f, 0x4c, 0x49, 0x53, 0x54, 0x10, |
| 196 |
0x06, 0x12, 0x15, 0x0a, 0x11, 0x4e, 0x4f, 0x4e, 0x5f, 0x45, 0x4d, 0x50, 0x54, 0x59, 0x5f, 0x44, |
| 197 |
0x45, 0x46, 0x41, 0x55, 0x4c, 0x54, 0x10, 0x07, 0x12, 0x0e, 0x0a, 0x0a, 0x49, 0x44, 0x45, 0x4e, |
| 198 |
0x54, 0x49, 0x46, 0x49, 0x45, 0x52, 0x10, 0x08, 0x3a, 0x64, 0x0a, 0x0e, 0x66, 0x69, 0x65, 0x6c, |
| 199 |
0x64, 0x5f, 0x62, 0x65, 0x68, 0x61, 0x76, 0x69, 0x6f, 0x72, 0x12, 0x1d, 0x2e, 0x67, 0x6f, 0x6f, |
| 200 |
0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x69, 0x65, |
| 201 |
0x6c, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x9c, 0x08, 0x20, 0x03, 0x28, 0x0e, |
| 202 |
0x32, 0x19, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x46, 0x69, |
| 203 |
0x65, 0x6c, 0x64, 0x42, 0x65, 0x68, 0x61, 0x76, 0x69, 0x6f, 0x72, 0x42, 0x02, 0x10, 0x00, 0x52, |
| 204 |
0x0d, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x42, 0x65, 0x68, 0x61, 0x76, 0x69, 0x6f, 0x72, 0x42, 0x70, |
| 205 |
0x0a, 0x0e, 0x63, 0x6f, 0x6d, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, |
| 206 |
0x42, 0x12, 0x46, 0x69, 0x65, 0x6c, 0x64, 0x42, 0x65, 0x68, 0x61, 0x76, 0x69, 0x6f, 0x72, 0x50, |
| 207 |
0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x41, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x67, |
| 208 |
0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x67, 0x65, 0x6e, 0x70, 0x72, 0x6f, |
| 209 |
0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x61, 0x70, 0x69, 0x73, 0x2f, 0x61, 0x70, |
| 210 |
0x69, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x3b, 0x61, 0x6e, |
| 211 |
0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0xa2, 0x02, 0x04, 0x47, 0x41, 0x50, 0x49, |
| 212 |
0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, |
| 213 |
} |
| 214 |
|
| 215 |
var ( |
| 216 |
file_google_api_field_behavior_proto_rawDescOnce sync.Once |
| 217 |
file_google_api_field_behavior_proto_rawDescData = file_google_api_field_behavior_proto_rawDesc |
| 218 |
) |
| 219 |
|
| 220 |
func file_google_api_field_behavior_proto_rawDescGZIP() []byte { |
| 221 |
file_google_api_field_behavior_proto_rawDescOnce.Do(func() { |
| 222 |
file_google_api_field_behavior_proto_rawDescData = protoimpl.X.CompressGZIP(file_google_api_field_behavior_proto_rawDescData) |
| 223 |
}) |
| 224 |
return file_google_api_field_behavior_proto_rawDescData |
| 225 |
} |
| 226 |
|
| 227 |
var file_google_api_field_behavior_proto_enumTypes = make([]protoimpl.EnumInfo, 1) |
| 228 |
var file_google_api_field_behavior_proto_goTypes = []interface{}{ |
| 229 |
(FieldBehavior)(0), // 0: google.api.FieldBehavior |
| 230 |
(*descriptorpb.FieldOptions)(nil), // 1: google.protobuf.FieldOptions |
| 231 |
} |
| 232 |
var file_google_api_field_behavior_proto_depIdxs = []int32{ |
| 233 |
1, // 0: google.api.field_behavior:extendee -> google.protobuf.FieldOptions |
| 234 |
0, // 1: google.api.field_behavior:type_name -> google.api.FieldBehavior |
| 235 |
2, // [2:2] is the sub-list for method output_type |
| 236 |
2, // [2:2] is the sub-list for method input_type |
| 237 |
1, // [1:2] is the sub-list for extension type_name |
| 238 |
0, // [0:1] is the sub-list for extension extendee |
| 239 |
0, // [0:0] is the sub-list for field type_name |
| 240 |
} |
| 241 |
|
| 242 |
func init() { file_google_api_field_behavior_proto_init() } |
| 243 |
func file_google_api_field_behavior_proto_init() { |
| 244 |
if File_google_api_field_behavior_proto != nil { |
| 245 |
return |
| 246 |
} |
| 247 |
type x struct{} |
| 248 |
out := protoimpl.TypeBuilder{ |
| 249 |
File: protoimpl.DescBuilder{ |
| 250 |
GoPackagePath: reflect.TypeOf(x{}).PkgPath(), |
| 251 |
RawDescriptor: file_google_api_field_behavior_proto_rawDesc, |
| 252 |
NumEnums: 1, |
| 253 |
NumMessages: 0, |
| 254 |
NumExtensions: 1, |
| 255 |
NumServices: 0, |
| 256 |
}, |
| 257 |
GoTypes: file_google_api_field_behavior_proto_goTypes, |
| 258 |
DependencyIndexes: file_google_api_field_behavior_proto_depIdxs, |
| 259 |
EnumInfos: file_google_api_field_behavior_proto_enumTypes, |
| 260 |
ExtensionInfos: file_google_api_field_behavior_proto_extTypes, |
| 261 |
}.Build() |
| 262 |
File_google_api_field_behavior_proto = out.File |
| 263 |
file_google_api_field_behavior_proto_rawDesc = nil |
| 264 |
file_google_api_field_behavior_proto_goTypes = nil |
| 265 |
file_google_api_field_behavior_proto_depIdxs = nil |
| 266 |
} |