github.com/cloudwan/edgelq-sdk@v1.15.4/iam/resources/v1/service_account_key/service_account_key.pb.fieldpath.go (about) 1 // Code generated by protoc-gen-goten-object 2 // File: edgelq/iam/proto/v1/service_account_key.proto 3 // DO NOT EDIT!!! 4 5 package service_account_key 6 7 import ( 8 "encoding/json" 9 "fmt" 10 "reflect" 11 "strings" 12 "time" 13 14 "google.golang.org/grpc/codes" 15 "google.golang.org/grpc/status" 16 "google.golang.org/protobuf/encoding/protojson" 17 "google.golang.org/protobuf/proto" 18 "google.golang.org/protobuf/reflect/protoregistry" 19 20 gotenobject "github.com/cloudwan/goten-sdk/runtime/object" 21 "github.com/cloudwan/goten-sdk/runtime/strcase" 22 ) 23 24 // proto imports 25 import ( 26 service_account "github.com/cloudwan/edgelq-sdk/iam/resources/v1/service_account" 27 meta "github.com/cloudwan/goten-sdk/types/meta" 28 timestamppb "google.golang.org/protobuf/types/known/timestamppb" 29 ) 30 31 // ensure the imports are used 32 var ( 33 _ = new(json.Marshaler) 34 _ = new(fmt.Stringer) 35 _ = reflect.DeepEqual 36 _ = strings.Builder{} 37 _ = time.Second 38 39 _ = strcase.ToLowerCamel 40 _ = codes.NotFound 41 _ = status.Status{} 42 _ = protojson.UnmarshalOptions{} 43 _ = new(proto.Message) 44 _ = protoregistry.GlobalTypes 45 46 _ = new(gotenobject.FieldPath) 47 ) 48 49 // make sure we're using proto imports 50 var ( 51 _ = &service_account.ServiceAccount{} 52 _ = ×tamppb.Timestamp{} 53 _ = &meta.Meta{} 54 ) 55 56 // FieldPath provides implementation to handle 57 // https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/field_mask.proto 58 type ServiceAccountKey_FieldPath interface { 59 gotenobject.FieldPath 60 Selector() ServiceAccountKey_FieldPathSelector 61 Get(source *ServiceAccountKey) []interface{} 62 GetSingle(source *ServiceAccountKey) (interface{}, bool) 63 ClearValue(item *ServiceAccountKey) 64 65 // Those methods build corresponding ServiceAccountKey_FieldPathValue 66 // (or array of values) and holds passed value. Panics if injected type is incorrect. 67 WithIValue(value interface{}) ServiceAccountKey_FieldPathValue 68 WithIArrayOfValues(values interface{}) ServiceAccountKey_FieldPathArrayOfValues 69 WithIArrayItemValue(value interface{}) ServiceAccountKey_FieldPathArrayItemValue 70 } 71 72 type ServiceAccountKey_FieldPathSelector int32 73 74 const ( 75 ServiceAccountKey_FieldPathSelectorName ServiceAccountKey_FieldPathSelector = 0 76 ServiceAccountKey_FieldPathSelectorMetadata ServiceAccountKey_FieldPathSelector = 1 77 ServiceAccountKey_FieldPathSelectorDisplayName ServiceAccountKey_FieldPathSelector = 2 78 ServiceAccountKey_FieldPathSelectorDescription ServiceAccountKey_FieldPathSelector = 3 79 ServiceAccountKey_FieldPathSelectorPublicKeyData ServiceAccountKey_FieldPathSelector = 4 80 ServiceAccountKey_FieldPathSelectorPrivateKeyData ServiceAccountKey_FieldPathSelector = 5 81 ServiceAccountKey_FieldPathSelectorApiKey ServiceAccountKey_FieldPathSelector = 6 82 ServiceAccountKey_FieldPathSelectorAlgorithm ServiceAccountKey_FieldPathSelector = 7 83 ServiceAccountKey_FieldPathSelectorValidNotBefore ServiceAccountKey_FieldPathSelector = 8 84 ServiceAccountKey_FieldPathSelectorValidNotAfter ServiceAccountKey_FieldPathSelector = 9 85 ) 86 87 func (s ServiceAccountKey_FieldPathSelector) String() string { 88 switch s { 89 case ServiceAccountKey_FieldPathSelectorName: 90 return "name" 91 case ServiceAccountKey_FieldPathSelectorMetadata: 92 return "metadata" 93 case ServiceAccountKey_FieldPathSelectorDisplayName: 94 return "display_name" 95 case ServiceAccountKey_FieldPathSelectorDescription: 96 return "description" 97 case ServiceAccountKey_FieldPathSelectorPublicKeyData: 98 return "public_key_data" 99 case ServiceAccountKey_FieldPathSelectorPrivateKeyData: 100 return "private_key_data" 101 case ServiceAccountKey_FieldPathSelectorApiKey: 102 return "api_key" 103 case ServiceAccountKey_FieldPathSelectorAlgorithm: 104 return "algorithm" 105 case ServiceAccountKey_FieldPathSelectorValidNotBefore: 106 return "valid_not_before" 107 case ServiceAccountKey_FieldPathSelectorValidNotAfter: 108 return "valid_not_after" 109 default: 110 panic(fmt.Sprintf("Invalid selector for ServiceAccountKey: %d", s)) 111 } 112 } 113 114 func BuildServiceAccountKey_FieldPath(fp gotenobject.RawFieldPath) (ServiceAccountKey_FieldPath, error) { 115 if len(fp) == 0 { 116 return nil, status.Error(codes.InvalidArgument, "empty field path for object ServiceAccountKey") 117 } 118 if len(fp) == 1 { 119 switch fp[0] { 120 case "name": 121 return &ServiceAccountKey_FieldTerminalPath{selector: ServiceAccountKey_FieldPathSelectorName}, nil 122 case "metadata": 123 return &ServiceAccountKey_FieldTerminalPath{selector: ServiceAccountKey_FieldPathSelectorMetadata}, nil 124 case "display_name", "displayName", "display-name": 125 return &ServiceAccountKey_FieldTerminalPath{selector: ServiceAccountKey_FieldPathSelectorDisplayName}, nil 126 case "description": 127 return &ServiceAccountKey_FieldTerminalPath{selector: ServiceAccountKey_FieldPathSelectorDescription}, nil 128 case "public_key_data", "publicKeyData", "public-key-data": 129 return &ServiceAccountKey_FieldTerminalPath{selector: ServiceAccountKey_FieldPathSelectorPublicKeyData}, nil 130 case "private_key_data", "privateKeyData", "private-key-data": 131 return &ServiceAccountKey_FieldTerminalPath{selector: ServiceAccountKey_FieldPathSelectorPrivateKeyData}, nil 132 case "api_key", "apiKey", "api-key": 133 return &ServiceAccountKey_FieldTerminalPath{selector: ServiceAccountKey_FieldPathSelectorApiKey}, nil 134 case "algorithm": 135 return &ServiceAccountKey_FieldTerminalPath{selector: ServiceAccountKey_FieldPathSelectorAlgorithm}, nil 136 case "valid_not_before", "validNotBefore", "valid-not-before": 137 return &ServiceAccountKey_FieldTerminalPath{selector: ServiceAccountKey_FieldPathSelectorValidNotBefore}, nil 138 case "valid_not_after", "validNotAfter", "valid-not-after": 139 return &ServiceAccountKey_FieldTerminalPath{selector: ServiceAccountKey_FieldPathSelectorValidNotAfter}, nil 140 } 141 } else { 142 switch fp[0] { 143 case "metadata": 144 if subpath, err := meta.BuildMeta_FieldPath(fp[1:]); err != nil { 145 return nil, err 146 } else { 147 return &ServiceAccountKey_FieldSubPath{selector: ServiceAccountKey_FieldPathSelectorMetadata, subPath: subpath}, nil 148 } 149 } 150 } 151 return nil, status.Errorf(codes.InvalidArgument, "unknown field path '%s' for object ServiceAccountKey", fp) 152 } 153 154 func ParseServiceAccountKey_FieldPath(rawField string) (ServiceAccountKey_FieldPath, error) { 155 fp, err := gotenobject.ParseRawFieldPath(rawField) 156 if err != nil { 157 return nil, err 158 } 159 return BuildServiceAccountKey_FieldPath(fp) 160 } 161 162 func MustParseServiceAccountKey_FieldPath(rawField string) ServiceAccountKey_FieldPath { 163 fp, err := ParseServiceAccountKey_FieldPath(rawField) 164 if err != nil { 165 panic(err) 166 } 167 return fp 168 } 169 170 type ServiceAccountKey_FieldTerminalPath struct { 171 selector ServiceAccountKey_FieldPathSelector 172 } 173 174 var _ ServiceAccountKey_FieldPath = (*ServiceAccountKey_FieldTerminalPath)(nil) 175 176 func (fp *ServiceAccountKey_FieldTerminalPath) Selector() ServiceAccountKey_FieldPathSelector { 177 return fp.selector 178 } 179 180 // String returns path representation in proto convention 181 func (fp *ServiceAccountKey_FieldTerminalPath) String() string { 182 return fp.selector.String() 183 } 184 185 // JSONString returns path representation is JSON convention 186 func (fp *ServiceAccountKey_FieldTerminalPath) JSONString() string { 187 return strcase.ToLowerCamel(fp.String()) 188 } 189 190 // Get returns all values pointed by specific field from source ServiceAccountKey 191 func (fp *ServiceAccountKey_FieldTerminalPath) Get(source *ServiceAccountKey) (values []interface{}) { 192 if source != nil { 193 switch fp.selector { 194 case ServiceAccountKey_FieldPathSelectorName: 195 if source.Name != nil { 196 values = append(values, source.Name) 197 } 198 case ServiceAccountKey_FieldPathSelectorMetadata: 199 if source.Metadata != nil { 200 values = append(values, source.Metadata) 201 } 202 case ServiceAccountKey_FieldPathSelectorDisplayName: 203 values = append(values, source.DisplayName) 204 case ServiceAccountKey_FieldPathSelectorDescription: 205 values = append(values, source.Description) 206 case ServiceAccountKey_FieldPathSelectorPublicKeyData: 207 values = append(values, source.PublicKeyData) 208 case ServiceAccountKey_FieldPathSelectorPrivateKeyData: 209 values = append(values, source.PrivateKeyData) 210 case ServiceAccountKey_FieldPathSelectorApiKey: 211 values = append(values, source.ApiKey) 212 case ServiceAccountKey_FieldPathSelectorAlgorithm: 213 values = append(values, source.Algorithm) 214 case ServiceAccountKey_FieldPathSelectorValidNotBefore: 215 if source.ValidNotBefore != nil { 216 values = append(values, source.ValidNotBefore) 217 } 218 case ServiceAccountKey_FieldPathSelectorValidNotAfter: 219 if source.ValidNotAfter != nil { 220 values = append(values, source.ValidNotAfter) 221 } 222 default: 223 panic(fmt.Sprintf("Invalid selector for ServiceAccountKey: %d", fp.selector)) 224 } 225 } 226 return 227 } 228 229 func (fp *ServiceAccountKey_FieldTerminalPath) GetRaw(source proto.Message) []interface{} { 230 return fp.Get(source.(*ServiceAccountKey)) 231 } 232 233 // GetSingle returns value pointed by specific field of from source ServiceAccountKey 234 func (fp *ServiceAccountKey_FieldTerminalPath) GetSingle(source *ServiceAccountKey) (interface{}, bool) { 235 switch fp.selector { 236 case ServiceAccountKey_FieldPathSelectorName: 237 res := source.GetName() 238 return res, res != nil 239 case ServiceAccountKey_FieldPathSelectorMetadata: 240 res := source.GetMetadata() 241 return res, res != nil 242 case ServiceAccountKey_FieldPathSelectorDisplayName: 243 return source.GetDisplayName(), source != nil 244 case ServiceAccountKey_FieldPathSelectorDescription: 245 return source.GetDescription(), source != nil 246 case ServiceAccountKey_FieldPathSelectorPublicKeyData: 247 return source.GetPublicKeyData(), source != nil 248 case ServiceAccountKey_FieldPathSelectorPrivateKeyData: 249 return source.GetPrivateKeyData(), source != nil 250 case ServiceAccountKey_FieldPathSelectorApiKey: 251 return source.GetApiKey(), source != nil 252 case ServiceAccountKey_FieldPathSelectorAlgorithm: 253 return source.GetAlgorithm(), source != nil 254 case ServiceAccountKey_FieldPathSelectorValidNotBefore: 255 res := source.GetValidNotBefore() 256 return res, res != nil 257 case ServiceAccountKey_FieldPathSelectorValidNotAfter: 258 res := source.GetValidNotAfter() 259 return res, res != nil 260 default: 261 panic(fmt.Sprintf("Invalid selector for ServiceAccountKey: %d", fp.selector)) 262 } 263 } 264 265 func (fp *ServiceAccountKey_FieldTerminalPath) GetSingleRaw(source proto.Message) (interface{}, bool) { 266 return fp.GetSingle(source.(*ServiceAccountKey)) 267 } 268 269 // GetDefault returns a default value of the field type 270 func (fp *ServiceAccountKey_FieldTerminalPath) GetDefault() interface{} { 271 switch fp.selector { 272 case ServiceAccountKey_FieldPathSelectorName: 273 return (*Name)(nil) 274 case ServiceAccountKey_FieldPathSelectorMetadata: 275 return (*meta.Meta)(nil) 276 case ServiceAccountKey_FieldPathSelectorDisplayName: 277 return "" 278 case ServiceAccountKey_FieldPathSelectorDescription: 279 return "" 280 case ServiceAccountKey_FieldPathSelectorPublicKeyData: 281 return "" 282 case ServiceAccountKey_FieldPathSelectorPrivateKeyData: 283 return "" 284 case ServiceAccountKey_FieldPathSelectorApiKey: 285 return "" 286 case ServiceAccountKey_FieldPathSelectorAlgorithm: 287 return ServiceAccountKey_KEY_ALGORITHM_UNSPECIFIED 288 case ServiceAccountKey_FieldPathSelectorValidNotBefore: 289 return (*timestamppb.Timestamp)(nil) 290 case ServiceAccountKey_FieldPathSelectorValidNotAfter: 291 return (*timestamppb.Timestamp)(nil) 292 default: 293 panic(fmt.Sprintf("Invalid selector for ServiceAccountKey: %d", fp.selector)) 294 } 295 } 296 297 func (fp *ServiceAccountKey_FieldTerminalPath) ClearValue(item *ServiceAccountKey) { 298 if item != nil { 299 switch fp.selector { 300 case ServiceAccountKey_FieldPathSelectorName: 301 item.Name = nil 302 case ServiceAccountKey_FieldPathSelectorMetadata: 303 item.Metadata = nil 304 case ServiceAccountKey_FieldPathSelectorDisplayName: 305 item.DisplayName = "" 306 case ServiceAccountKey_FieldPathSelectorDescription: 307 item.Description = "" 308 case ServiceAccountKey_FieldPathSelectorPublicKeyData: 309 item.PublicKeyData = "" 310 case ServiceAccountKey_FieldPathSelectorPrivateKeyData: 311 item.PrivateKeyData = "" 312 case ServiceAccountKey_FieldPathSelectorApiKey: 313 item.ApiKey = "" 314 case ServiceAccountKey_FieldPathSelectorAlgorithm: 315 item.Algorithm = ServiceAccountKey_KEY_ALGORITHM_UNSPECIFIED 316 case ServiceAccountKey_FieldPathSelectorValidNotBefore: 317 item.ValidNotBefore = nil 318 case ServiceAccountKey_FieldPathSelectorValidNotAfter: 319 item.ValidNotAfter = nil 320 default: 321 panic(fmt.Sprintf("Invalid selector for ServiceAccountKey: %d", fp.selector)) 322 } 323 } 324 } 325 326 func (fp *ServiceAccountKey_FieldTerminalPath) ClearValueRaw(item proto.Message) { 327 fp.ClearValue(item.(*ServiceAccountKey)) 328 } 329 330 // IsLeaf - whether field path is holds simple value 331 func (fp *ServiceAccountKey_FieldTerminalPath) IsLeaf() bool { 332 return fp.selector == ServiceAccountKey_FieldPathSelectorName || 333 fp.selector == ServiceAccountKey_FieldPathSelectorDisplayName || 334 fp.selector == ServiceAccountKey_FieldPathSelectorDescription || 335 fp.selector == ServiceAccountKey_FieldPathSelectorPublicKeyData || 336 fp.selector == ServiceAccountKey_FieldPathSelectorPrivateKeyData || 337 fp.selector == ServiceAccountKey_FieldPathSelectorApiKey || 338 fp.selector == ServiceAccountKey_FieldPathSelectorAlgorithm || 339 fp.selector == ServiceAccountKey_FieldPathSelectorValidNotBefore || 340 fp.selector == ServiceAccountKey_FieldPathSelectorValidNotAfter 341 } 342 343 func (fp *ServiceAccountKey_FieldTerminalPath) SplitIntoTerminalIPaths() []gotenobject.FieldPath { 344 return []gotenobject.FieldPath{fp} 345 } 346 347 func (fp *ServiceAccountKey_FieldTerminalPath) WithIValue(value interface{}) ServiceAccountKey_FieldPathValue { 348 switch fp.selector { 349 case ServiceAccountKey_FieldPathSelectorName: 350 return &ServiceAccountKey_FieldTerminalPathValue{ServiceAccountKey_FieldTerminalPath: *fp, value: value.(*Name)} 351 case ServiceAccountKey_FieldPathSelectorMetadata: 352 return &ServiceAccountKey_FieldTerminalPathValue{ServiceAccountKey_FieldTerminalPath: *fp, value: value.(*meta.Meta)} 353 case ServiceAccountKey_FieldPathSelectorDisplayName: 354 return &ServiceAccountKey_FieldTerminalPathValue{ServiceAccountKey_FieldTerminalPath: *fp, value: value.(string)} 355 case ServiceAccountKey_FieldPathSelectorDescription: 356 return &ServiceAccountKey_FieldTerminalPathValue{ServiceAccountKey_FieldTerminalPath: *fp, value: value.(string)} 357 case ServiceAccountKey_FieldPathSelectorPublicKeyData: 358 return &ServiceAccountKey_FieldTerminalPathValue{ServiceAccountKey_FieldTerminalPath: *fp, value: value.(string)} 359 case ServiceAccountKey_FieldPathSelectorPrivateKeyData: 360 return &ServiceAccountKey_FieldTerminalPathValue{ServiceAccountKey_FieldTerminalPath: *fp, value: value.(string)} 361 case ServiceAccountKey_FieldPathSelectorApiKey: 362 return &ServiceAccountKey_FieldTerminalPathValue{ServiceAccountKey_FieldTerminalPath: *fp, value: value.(string)} 363 case ServiceAccountKey_FieldPathSelectorAlgorithm: 364 return &ServiceAccountKey_FieldTerminalPathValue{ServiceAccountKey_FieldTerminalPath: *fp, value: value.(ServiceAccountKey_Algorithm)} 365 case ServiceAccountKey_FieldPathSelectorValidNotBefore: 366 return &ServiceAccountKey_FieldTerminalPathValue{ServiceAccountKey_FieldTerminalPath: *fp, value: value.(*timestamppb.Timestamp)} 367 case ServiceAccountKey_FieldPathSelectorValidNotAfter: 368 return &ServiceAccountKey_FieldTerminalPathValue{ServiceAccountKey_FieldTerminalPath: *fp, value: value.(*timestamppb.Timestamp)} 369 default: 370 panic(fmt.Sprintf("Invalid selector for ServiceAccountKey: %d", fp.selector)) 371 } 372 } 373 374 func (fp *ServiceAccountKey_FieldTerminalPath) WithRawIValue(value interface{}) gotenobject.FieldPathValue { 375 return fp.WithIValue(value) 376 } 377 378 func (fp *ServiceAccountKey_FieldTerminalPath) WithIArrayOfValues(values interface{}) ServiceAccountKey_FieldPathArrayOfValues { 379 fpaov := &ServiceAccountKey_FieldTerminalPathArrayOfValues{ServiceAccountKey_FieldTerminalPath: *fp} 380 switch fp.selector { 381 case ServiceAccountKey_FieldPathSelectorName: 382 return &ServiceAccountKey_FieldTerminalPathArrayOfValues{ServiceAccountKey_FieldTerminalPath: *fp, values: values.([]*Name)} 383 case ServiceAccountKey_FieldPathSelectorMetadata: 384 return &ServiceAccountKey_FieldTerminalPathArrayOfValues{ServiceAccountKey_FieldTerminalPath: *fp, values: values.([]*meta.Meta)} 385 case ServiceAccountKey_FieldPathSelectorDisplayName: 386 return &ServiceAccountKey_FieldTerminalPathArrayOfValues{ServiceAccountKey_FieldTerminalPath: *fp, values: values.([]string)} 387 case ServiceAccountKey_FieldPathSelectorDescription: 388 return &ServiceAccountKey_FieldTerminalPathArrayOfValues{ServiceAccountKey_FieldTerminalPath: *fp, values: values.([]string)} 389 case ServiceAccountKey_FieldPathSelectorPublicKeyData: 390 return &ServiceAccountKey_FieldTerminalPathArrayOfValues{ServiceAccountKey_FieldTerminalPath: *fp, values: values.([]string)} 391 case ServiceAccountKey_FieldPathSelectorPrivateKeyData: 392 return &ServiceAccountKey_FieldTerminalPathArrayOfValues{ServiceAccountKey_FieldTerminalPath: *fp, values: values.([]string)} 393 case ServiceAccountKey_FieldPathSelectorApiKey: 394 return &ServiceAccountKey_FieldTerminalPathArrayOfValues{ServiceAccountKey_FieldTerminalPath: *fp, values: values.([]string)} 395 case ServiceAccountKey_FieldPathSelectorAlgorithm: 396 return &ServiceAccountKey_FieldTerminalPathArrayOfValues{ServiceAccountKey_FieldTerminalPath: *fp, values: values.([]ServiceAccountKey_Algorithm)} 397 case ServiceAccountKey_FieldPathSelectorValidNotBefore: 398 return &ServiceAccountKey_FieldTerminalPathArrayOfValues{ServiceAccountKey_FieldTerminalPath: *fp, values: values.([]*timestamppb.Timestamp)} 399 case ServiceAccountKey_FieldPathSelectorValidNotAfter: 400 return &ServiceAccountKey_FieldTerminalPathArrayOfValues{ServiceAccountKey_FieldTerminalPath: *fp, values: values.([]*timestamppb.Timestamp)} 401 default: 402 panic(fmt.Sprintf("Invalid selector for ServiceAccountKey: %d", fp.selector)) 403 } 404 return fpaov 405 } 406 407 func (fp *ServiceAccountKey_FieldTerminalPath) WithRawIArrayOfValues(values interface{}) gotenobject.FieldPathArrayOfValues { 408 return fp.WithIArrayOfValues(values) 409 } 410 411 func (fp *ServiceAccountKey_FieldTerminalPath) WithIArrayItemValue(value interface{}) ServiceAccountKey_FieldPathArrayItemValue { 412 switch fp.selector { 413 default: 414 panic(fmt.Sprintf("Invalid selector for ServiceAccountKey: %d", fp.selector)) 415 } 416 } 417 418 func (fp *ServiceAccountKey_FieldTerminalPath) WithRawIArrayItemValue(value interface{}) gotenobject.FieldPathArrayItemValue { 419 return fp.WithIArrayItemValue(value) 420 } 421 422 type ServiceAccountKey_FieldSubPath struct { 423 selector ServiceAccountKey_FieldPathSelector 424 subPath gotenobject.FieldPath 425 } 426 427 var _ ServiceAccountKey_FieldPath = (*ServiceAccountKey_FieldSubPath)(nil) 428 429 func (fps *ServiceAccountKey_FieldSubPath) Selector() ServiceAccountKey_FieldPathSelector { 430 return fps.selector 431 } 432 func (fps *ServiceAccountKey_FieldSubPath) AsMetadataSubPath() (meta.Meta_FieldPath, bool) { 433 res, ok := fps.subPath.(meta.Meta_FieldPath) 434 return res, ok 435 } 436 437 // String returns path representation in proto convention 438 func (fps *ServiceAccountKey_FieldSubPath) String() string { 439 return fps.selector.String() + "." + fps.subPath.String() 440 } 441 442 // JSONString returns path representation is JSON convention 443 func (fps *ServiceAccountKey_FieldSubPath) JSONString() string { 444 return strcase.ToLowerCamel(fps.selector.String()) + "." + fps.subPath.JSONString() 445 } 446 447 // Get returns all values pointed by selected field from source ServiceAccountKey 448 func (fps *ServiceAccountKey_FieldSubPath) Get(source *ServiceAccountKey) (values []interface{}) { 449 switch fps.selector { 450 case ServiceAccountKey_FieldPathSelectorMetadata: 451 values = append(values, fps.subPath.GetRaw(source.GetMetadata())...) 452 default: 453 panic(fmt.Sprintf("Invalid selector for ServiceAccountKey: %d", fps.selector)) 454 } 455 return 456 } 457 458 func (fps *ServiceAccountKey_FieldSubPath) GetRaw(source proto.Message) []interface{} { 459 return fps.Get(source.(*ServiceAccountKey)) 460 } 461 462 // GetSingle returns value of selected field from source ServiceAccountKey 463 func (fps *ServiceAccountKey_FieldSubPath) GetSingle(source *ServiceAccountKey) (interface{}, bool) { 464 switch fps.selector { 465 case ServiceAccountKey_FieldPathSelectorMetadata: 466 if source.GetMetadata() == nil { 467 return nil, false 468 } 469 return fps.subPath.GetSingleRaw(source.GetMetadata()) 470 default: 471 panic(fmt.Sprintf("Invalid selector for ServiceAccountKey: %d", fps.selector)) 472 } 473 } 474 475 func (fps *ServiceAccountKey_FieldSubPath) GetSingleRaw(source proto.Message) (interface{}, bool) { 476 return fps.GetSingle(source.(*ServiceAccountKey)) 477 } 478 479 // GetDefault returns a default value of the field type 480 func (fps *ServiceAccountKey_FieldSubPath) GetDefault() interface{} { 481 return fps.subPath.GetDefault() 482 } 483 484 func (fps *ServiceAccountKey_FieldSubPath) ClearValue(item *ServiceAccountKey) { 485 if item != nil { 486 switch fps.selector { 487 case ServiceAccountKey_FieldPathSelectorMetadata: 488 fps.subPath.ClearValueRaw(item.Metadata) 489 default: 490 panic(fmt.Sprintf("Invalid selector for ServiceAccountKey: %d", fps.selector)) 491 } 492 } 493 } 494 495 func (fps *ServiceAccountKey_FieldSubPath) ClearValueRaw(item proto.Message) { 496 fps.ClearValue(item.(*ServiceAccountKey)) 497 } 498 499 // IsLeaf - whether field path is holds simple value 500 func (fps *ServiceAccountKey_FieldSubPath) IsLeaf() bool { 501 return fps.subPath.IsLeaf() 502 } 503 504 func (fps *ServiceAccountKey_FieldSubPath) SplitIntoTerminalIPaths() []gotenobject.FieldPath { 505 iPaths := []gotenobject.FieldPath{&ServiceAccountKey_FieldTerminalPath{selector: fps.selector}} 506 iPaths = append(iPaths, fps.subPath.SplitIntoTerminalIPaths()...) 507 return iPaths 508 } 509 510 func (fps *ServiceAccountKey_FieldSubPath) WithIValue(value interface{}) ServiceAccountKey_FieldPathValue { 511 return &ServiceAccountKey_FieldSubPathValue{fps, fps.subPath.WithRawIValue(value)} 512 } 513 514 func (fps *ServiceAccountKey_FieldSubPath) WithRawIValue(value interface{}) gotenobject.FieldPathValue { 515 return fps.WithIValue(value) 516 } 517 518 func (fps *ServiceAccountKey_FieldSubPath) WithIArrayOfValues(values interface{}) ServiceAccountKey_FieldPathArrayOfValues { 519 return &ServiceAccountKey_FieldSubPathArrayOfValues{fps, fps.subPath.WithRawIArrayOfValues(values)} 520 } 521 522 func (fps *ServiceAccountKey_FieldSubPath) WithRawIArrayOfValues(values interface{}) gotenobject.FieldPathArrayOfValues { 523 return fps.WithIArrayOfValues(values) 524 } 525 526 func (fps *ServiceAccountKey_FieldSubPath) WithIArrayItemValue(value interface{}) ServiceAccountKey_FieldPathArrayItemValue { 527 return &ServiceAccountKey_FieldSubPathArrayItemValue{fps, fps.subPath.WithRawIArrayItemValue(value)} 528 } 529 530 func (fps *ServiceAccountKey_FieldSubPath) WithRawIArrayItemValue(value interface{}) gotenobject.FieldPathArrayItemValue { 531 return fps.WithIArrayItemValue(value) 532 } 533 534 // ServiceAccountKey_FieldPathValue allows storing values for ServiceAccountKey fields according to their type 535 type ServiceAccountKey_FieldPathValue interface { 536 ServiceAccountKey_FieldPath 537 gotenobject.FieldPathValue 538 SetTo(target **ServiceAccountKey) 539 CompareWith(*ServiceAccountKey) (cmp int, comparable bool) 540 } 541 542 func ParseServiceAccountKey_FieldPathValue(pathStr, valueStr string) (ServiceAccountKey_FieldPathValue, error) { 543 fp, err := ParseServiceAccountKey_FieldPath(pathStr) 544 if err != nil { 545 return nil, err 546 } 547 fpv, err := gotenobject.ParseFieldPathValue(fp, valueStr) 548 if err != nil { 549 return nil, status.Errorf(codes.InvalidArgument, "error parsing ServiceAccountKey field path value from %s: %v", valueStr, err) 550 } 551 return fpv.(ServiceAccountKey_FieldPathValue), nil 552 } 553 554 func MustParseServiceAccountKey_FieldPathValue(pathStr, valueStr string) ServiceAccountKey_FieldPathValue { 555 fpv, err := ParseServiceAccountKey_FieldPathValue(pathStr, valueStr) 556 if err != nil { 557 panic(err) 558 } 559 return fpv 560 } 561 562 type ServiceAccountKey_FieldTerminalPathValue struct { 563 ServiceAccountKey_FieldTerminalPath 564 value interface{} 565 } 566 567 var _ ServiceAccountKey_FieldPathValue = (*ServiceAccountKey_FieldTerminalPathValue)(nil) 568 569 // GetRawValue returns raw value stored under selected path for 'ServiceAccountKey' as interface{} 570 func (fpv *ServiceAccountKey_FieldTerminalPathValue) GetRawValue() interface{} { 571 return fpv.value 572 } 573 func (fpv *ServiceAccountKey_FieldTerminalPathValue) AsNameValue() (*Name, bool) { 574 res, ok := fpv.value.(*Name) 575 return res, ok 576 } 577 func (fpv *ServiceAccountKey_FieldTerminalPathValue) AsMetadataValue() (*meta.Meta, bool) { 578 res, ok := fpv.value.(*meta.Meta) 579 return res, ok 580 } 581 func (fpv *ServiceAccountKey_FieldTerminalPathValue) AsDisplayNameValue() (string, bool) { 582 res, ok := fpv.value.(string) 583 return res, ok 584 } 585 func (fpv *ServiceAccountKey_FieldTerminalPathValue) AsDescriptionValue() (string, bool) { 586 res, ok := fpv.value.(string) 587 return res, ok 588 } 589 func (fpv *ServiceAccountKey_FieldTerminalPathValue) AsPublicKeyDataValue() (string, bool) { 590 res, ok := fpv.value.(string) 591 return res, ok 592 } 593 func (fpv *ServiceAccountKey_FieldTerminalPathValue) AsPrivateKeyDataValue() (string, bool) { 594 res, ok := fpv.value.(string) 595 return res, ok 596 } 597 func (fpv *ServiceAccountKey_FieldTerminalPathValue) AsApiKeyValue() (string, bool) { 598 res, ok := fpv.value.(string) 599 return res, ok 600 } 601 func (fpv *ServiceAccountKey_FieldTerminalPathValue) AsAlgorithmValue() (ServiceAccountKey_Algorithm, bool) { 602 res, ok := fpv.value.(ServiceAccountKey_Algorithm) 603 return res, ok 604 } 605 func (fpv *ServiceAccountKey_FieldTerminalPathValue) AsValidNotBeforeValue() (*timestamppb.Timestamp, bool) { 606 res, ok := fpv.value.(*timestamppb.Timestamp) 607 return res, ok 608 } 609 func (fpv *ServiceAccountKey_FieldTerminalPathValue) AsValidNotAfterValue() (*timestamppb.Timestamp, bool) { 610 res, ok := fpv.value.(*timestamppb.Timestamp) 611 return res, ok 612 } 613 614 // SetTo stores value for selected field for object ServiceAccountKey 615 func (fpv *ServiceAccountKey_FieldTerminalPathValue) SetTo(target **ServiceAccountKey) { 616 if *target == nil { 617 *target = new(ServiceAccountKey) 618 } 619 switch fpv.selector { 620 case ServiceAccountKey_FieldPathSelectorName: 621 (*target).Name = fpv.value.(*Name) 622 case ServiceAccountKey_FieldPathSelectorMetadata: 623 (*target).Metadata = fpv.value.(*meta.Meta) 624 case ServiceAccountKey_FieldPathSelectorDisplayName: 625 (*target).DisplayName = fpv.value.(string) 626 case ServiceAccountKey_FieldPathSelectorDescription: 627 (*target).Description = fpv.value.(string) 628 case ServiceAccountKey_FieldPathSelectorPublicKeyData: 629 (*target).PublicKeyData = fpv.value.(string) 630 case ServiceAccountKey_FieldPathSelectorPrivateKeyData: 631 (*target).PrivateKeyData = fpv.value.(string) 632 case ServiceAccountKey_FieldPathSelectorApiKey: 633 (*target).ApiKey = fpv.value.(string) 634 case ServiceAccountKey_FieldPathSelectorAlgorithm: 635 (*target).Algorithm = fpv.value.(ServiceAccountKey_Algorithm) 636 case ServiceAccountKey_FieldPathSelectorValidNotBefore: 637 (*target).ValidNotBefore = fpv.value.(*timestamppb.Timestamp) 638 case ServiceAccountKey_FieldPathSelectorValidNotAfter: 639 (*target).ValidNotAfter = fpv.value.(*timestamppb.Timestamp) 640 default: 641 panic(fmt.Sprintf("Invalid selector for ServiceAccountKey: %d", fpv.selector)) 642 } 643 } 644 645 func (fpv *ServiceAccountKey_FieldTerminalPathValue) SetToRaw(target proto.Message) { 646 typedObject := target.(*ServiceAccountKey) 647 fpv.SetTo(&typedObject) 648 } 649 650 // CompareWith compares value in the 'ServiceAccountKey_FieldTerminalPathValue' with the value under path in 'ServiceAccountKey'. 651 func (fpv *ServiceAccountKey_FieldTerminalPathValue) CompareWith(source *ServiceAccountKey) (int, bool) { 652 switch fpv.selector { 653 case ServiceAccountKey_FieldPathSelectorName: 654 leftValue := fpv.value.(*Name) 655 rightValue := source.GetName() 656 if leftValue == nil { 657 if rightValue != nil { 658 return -1, true 659 } 660 return 0, true 661 } 662 if rightValue == nil { 663 return 1, true 664 } 665 if leftValue.String() == rightValue.String() { 666 return 0, true 667 } else if leftValue.String() < rightValue.String() { 668 return -1, true 669 } else { 670 return 1, true 671 } 672 case ServiceAccountKey_FieldPathSelectorMetadata: 673 return 0, false 674 case ServiceAccountKey_FieldPathSelectorDisplayName: 675 leftValue := fpv.value.(string) 676 rightValue := source.GetDisplayName() 677 if (leftValue) == (rightValue) { 678 return 0, true 679 } else if (leftValue) < (rightValue) { 680 return -1, true 681 } else { 682 return 1, true 683 } 684 case ServiceAccountKey_FieldPathSelectorDescription: 685 leftValue := fpv.value.(string) 686 rightValue := source.GetDescription() 687 if (leftValue) == (rightValue) { 688 return 0, true 689 } else if (leftValue) < (rightValue) { 690 return -1, true 691 } else { 692 return 1, true 693 } 694 case ServiceAccountKey_FieldPathSelectorPublicKeyData: 695 leftValue := fpv.value.(string) 696 rightValue := source.GetPublicKeyData() 697 if (leftValue) == (rightValue) { 698 return 0, true 699 } else if (leftValue) < (rightValue) { 700 return -1, true 701 } else { 702 return 1, true 703 } 704 case ServiceAccountKey_FieldPathSelectorPrivateKeyData: 705 leftValue := fpv.value.(string) 706 rightValue := source.GetPrivateKeyData() 707 if (leftValue) == (rightValue) { 708 return 0, true 709 } else if (leftValue) < (rightValue) { 710 return -1, true 711 } else { 712 return 1, true 713 } 714 case ServiceAccountKey_FieldPathSelectorApiKey: 715 leftValue := fpv.value.(string) 716 rightValue := source.GetApiKey() 717 if (leftValue) == (rightValue) { 718 return 0, true 719 } else if (leftValue) < (rightValue) { 720 return -1, true 721 } else { 722 return 1, true 723 } 724 case ServiceAccountKey_FieldPathSelectorAlgorithm: 725 leftValue := fpv.value.(ServiceAccountKey_Algorithm) 726 rightValue := source.GetAlgorithm() 727 if (leftValue) == (rightValue) { 728 return 0, true 729 } else if (leftValue) < (rightValue) { 730 return -1, true 731 } else { 732 return 1, true 733 } 734 case ServiceAccountKey_FieldPathSelectorValidNotBefore: 735 leftValue := fpv.value.(*timestamppb.Timestamp) 736 rightValue := source.GetValidNotBefore() 737 if leftValue == nil { 738 if rightValue != nil { 739 return -1, true 740 } 741 return 0, true 742 } 743 if rightValue == nil { 744 return 1, true 745 } 746 if leftValue.AsTime().Equal(rightValue.AsTime()) { 747 return 0, true 748 } else if leftValue.AsTime().Before(rightValue.AsTime()) { 749 return -1, true 750 } else { 751 return 1, true 752 } 753 case ServiceAccountKey_FieldPathSelectorValidNotAfter: 754 leftValue := fpv.value.(*timestamppb.Timestamp) 755 rightValue := source.GetValidNotAfter() 756 if leftValue == nil { 757 if rightValue != nil { 758 return -1, true 759 } 760 return 0, true 761 } 762 if rightValue == nil { 763 return 1, true 764 } 765 if leftValue.AsTime().Equal(rightValue.AsTime()) { 766 return 0, true 767 } else if leftValue.AsTime().Before(rightValue.AsTime()) { 768 return -1, true 769 } else { 770 return 1, true 771 } 772 default: 773 panic(fmt.Sprintf("Invalid selector for ServiceAccountKey: %d", fpv.selector)) 774 } 775 } 776 777 func (fpv *ServiceAccountKey_FieldTerminalPathValue) CompareWithRaw(source proto.Message) (int, bool) { 778 return fpv.CompareWith(source.(*ServiceAccountKey)) 779 } 780 781 type ServiceAccountKey_FieldSubPathValue struct { 782 ServiceAccountKey_FieldPath 783 subPathValue gotenobject.FieldPathValue 784 } 785 786 var _ ServiceAccountKey_FieldPathValue = (*ServiceAccountKey_FieldSubPathValue)(nil) 787 788 func (fpvs *ServiceAccountKey_FieldSubPathValue) AsMetadataPathValue() (meta.Meta_FieldPathValue, bool) { 789 res, ok := fpvs.subPathValue.(meta.Meta_FieldPathValue) 790 return res, ok 791 } 792 793 func (fpvs *ServiceAccountKey_FieldSubPathValue) SetTo(target **ServiceAccountKey) { 794 if *target == nil { 795 *target = new(ServiceAccountKey) 796 } 797 switch fpvs.Selector() { 798 case ServiceAccountKey_FieldPathSelectorMetadata: 799 fpvs.subPathValue.(meta.Meta_FieldPathValue).SetTo(&(*target).Metadata) 800 default: 801 panic(fmt.Sprintf("Invalid selector for ServiceAccountKey: %d", fpvs.Selector())) 802 } 803 } 804 805 func (fpvs *ServiceAccountKey_FieldSubPathValue) SetToRaw(target proto.Message) { 806 typedObject := target.(*ServiceAccountKey) 807 fpvs.SetTo(&typedObject) 808 } 809 810 func (fpvs *ServiceAccountKey_FieldSubPathValue) GetRawValue() interface{} { 811 return fpvs.subPathValue.GetRawValue() 812 } 813 814 func (fpvs *ServiceAccountKey_FieldSubPathValue) CompareWith(source *ServiceAccountKey) (int, bool) { 815 switch fpvs.Selector() { 816 case ServiceAccountKey_FieldPathSelectorMetadata: 817 return fpvs.subPathValue.(meta.Meta_FieldPathValue).CompareWith(source.GetMetadata()) 818 default: 819 panic(fmt.Sprintf("Invalid selector for ServiceAccountKey: %d", fpvs.Selector())) 820 } 821 } 822 823 func (fpvs *ServiceAccountKey_FieldSubPathValue) CompareWithRaw(source proto.Message) (int, bool) { 824 return fpvs.CompareWith(source.(*ServiceAccountKey)) 825 } 826 827 // ServiceAccountKey_FieldPathArrayItemValue allows storing single item in Path-specific values for ServiceAccountKey according to their type 828 // Present only for array (repeated) types. 829 type ServiceAccountKey_FieldPathArrayItemValue interface { 830 gotenobject.FieldPathArrayItemValue 831 ServiceAccountKey_FieldPath 832 ContainsValue(*ServiceAccountKey) bool 833 } 834 835 // ParseServiceAccountKey_FieldPathArrayItemValue parses string and JSON-encoded value to its Value 836 func ParseServiceAccountKey_FieldPathArrayItemValue(pathStr, valueStr string) (ServiceAccountKey_FieldPathArrayItemValue, error) { 837 fp, err := ParseServiceAccountKey_FieldPath(pathStr) 838 if err != nil { 839 return nil, err 840 } 841 fpaiv, err := gotenobject.ParseFieldPathArrayItemValue(fp, valueStr) 842 if err != nil { 843 return nil, status.Errorf(codes.InvalidArgument, "error parsing ServiceAccountKey field path array item value from %s: %v", valueStr, err) 844 } 845 return fpaiv.(ServiceAccountKey_FieldPathArrayItemValue), nil 846 } 847 848 func MustParseServiceAccountKey_FieldPathArrayItemValue(pathStr, valueStr string) ServiceAccountKey_FieldPathArrayItemValue { 849 fpaiv, err := ParseServiceAccountKey_FieldPathArrayItemValue(pathStr, valueStr) 850 if err != nil { 851 panic(err) 852 } 853 return fpaiv 854 } 855 856 type ServiceAccountKey_FieldTerminalPathArrayItemValue struct { 857 ServiceAccountKey_FieldTerminalPath 858 value interface{} 859 } 860 861 var _ ServiceAccountKey_FieldPathArrayItemValue = (*ServiceAccountKey_FieldTerminalPathArrayItemValue)(nil) 862 863 // GetRawValue returns stored element value for array in object ServiceAccountKey as interface{} 864 func (fpaiv *ServiceAccountKey_FieldTerminalPathArrayItemValue) GetRawItemValue() interface{} { 865 return fpaiv.value 866 } 867 868 func (fpaiv *ServiceAccountKey_FieldTerminalPathArrayItemValue) GetSingle(source *ServiceAccountKey) (interface{}, bool) { 869 return nil, false 870 } 871 872 func (fpaiv *ServiceAccountKey_FieldTerminalPathArrayItemValue) GetSingleRaw(source proto.Message) (interface{}, bool) { 873 return fpaiv.GetSingle(source.(*ServiceAccountKey)) 874 } 875 876 // Contains returns a boolean indicating if value that is being held is present in given 'ServiceAccountKey' 877 func (fpaiv *ServiceAccountKey_FieldTerminalPathArrayItemValue) ContainsValue(source *ServiceAccountKey) bool { 878 slice := fpaiv.ServiceAccountKey_FieldTerminalPath.Get(source) 879 for _, v := range slice { 880 if asProtoMsg, ok := fpaiv.value.(proto.Message); ok { 881 if proto.Equal(asProtoMsg, v.(proto.Message)) { 882 return true 883 } 884 } else if reflect.DeepEqual(v, fpaiv.value) { 885 return true 886 } 887 } 888 return false 889 } 890 891 type ServiceAccountKey_FieldSubPathArrayItemValue struct { 892 ServiceAccountKey_FieldPath 893 subPathItemValue gotenobject.FieldPathArrayItemValue 894 } 895 896 // GetRawValue returns stored array item value 897 func (fpaivs *ServiceAccountKey_FieldSubPathArrayItemValue) GetRawItemValue() interface{} { 898 return fpaivs.subPathItemValue.GetRawItemValue() 899 } 900 func (fpaivs *ServiceAccountKey_FieldSubPathArrayItemValue) AsMetadataPathItemValue() (meta.Meta_FieldPathArrayItemValue, bool) { 901 res, ok := fpaivs.subPathItemValue.(meta.Meta_FieldPathArrayItemValue) 902 return res, ok 903 } 904 905 // Contains returns a boolean indicating if value that is being held is present in given 'ServiceAccountKey' 906 func (fpaivs *ServiceAccountKey_FieldSubPathArrayItemValue) ContainsValue(source *ServiceAccountKey) bool { 907 switch fpaivs.Selector() { 908 case ServiceAccountKey_FieldPathSelectorMetadata: 909 return fpaivs.subPathItemValue.(meta.Meta_FieldPathArrayItemValue).ContainsValue(source.GetMetadata()) 910 default: 911 panic(fmt.Sprintf("Invalid selector for ServiceAccountKey: %d", fpaivs.Selector())) 912 } 913 } 914 915 // ServiceAccountKey_FieldPathArrayOfValues allows storing slice of values for ServiceAccountKey fields according to their type 916 type ServiceAccountKey_FieldPathArrayOfValues interface { 917 gotenobject.FieldPathArrayOfValues 918 ServiceAccountKey_FieldPath 919 } 920 921 func ParseServiceAccountKey_FieldPathArrayOfValues(pathStr, valuesStr string) (ServiceAccountKey_FieldPathArrayOfValues, error) { 922 fp, err := ParseServiceAccountKey_FieldPath(pathStr) 923 if err != nil { 924 return nil, err 925 } 926 fpaov, err := gotenobject.ParseFieldPathArrayOfValues(fp, valuesStr) 927 if err != nil { 928 return nil, status.Errorf(codes.InvalidArgument, "error parsing ServiceAccountKey field path array of values from %s: %v", valuesStr, err) 929 } 930 return fpaov.(ServiceAccountKey_FieldPathArrayOfValues), nil 931 } 932 933 func MustParseServiceAccountKey_FieldPathArrayOfValues(pathStr, valuesStr string) ServiceAccountKey_FieldPathArrayOfValues { 934 fpaov, err := ParseServiceAccountKey_FieldPathArrayOfValues(pathStr, valuesStr) 935 if err != nil { 936 panic(err) 937 } 938 return fpaov 939 } 940 941 type ServiceAccountKey_FieldTerminalPathArrayOfValues struct { 942 ServiceAccountKey_FieldTerminalPath 943 values interface{} 944 } 945 946 var _ ServiceAccountKey_FieldPathArrayOfValues = (*ServiceAccountKey_FieldTerminalPathArrayOfValues)(nil) 947 948 func (fpaov *ServiceAccountKey_FieldTerminalPathArrayOfValues) GetRawValues() (values []interface{}) { 949 switch fpaov.selector { 950 case ServiceAccountKey_FieldPathSelectorName: 951 for _, v := range fpaov.values.([]*Name) { 952 values = append(values, v) 953 } 954 case ServiceAccountKey_FieldPathSelectorMetadata: 955 for _, v := range fpaov.values.([]*meta.Meta) { 956 values = append(values, v) 957 } 958 case ServiceAccountKey_FieldPathSelectorDisplayName: 959 for _, v := range fpaov.values.([]string) { 960 values = append(values, v) 961 } 962 case ServiceAccountKey_FieldPathSelectorDescription: 963 for _, v := range fpaov.values.([]string) { 964 values = append(values, v) 965 } 966 case ServiceAccountKey_FieldPathSelectorPublicKeyData: 967 for _, v := range fpaov.values.([]string) { 968 values = append(values, v) 969 } 970 case ServiceAccountKey_FieldPathSelectorPrivateKeyData: 971 for _, v := range fpaov.values.([]string) { 972 values = append(values, v) 973 } 974 case ServiceAccountKey_FieldPathSelectorApiKey: 975 for _, v := range fpaov.values.([]string) { 976 values = append(values, v) 977 } 978 case ServiceAccountKey_FieldPathSelectorAlgorithm: 979 for _, v := range fpaov.values.([]ServiceAccountKey_Algorithm) { 980 values = append(values, v) 981 } 982 case ServiceAccountKey_FieldPathSelectorValidNotBefore: 983 for _, v := range fpaov.values.([]*timestamppb.Timestamp) { 984 values = append(values, v) 985 } 986 case ServiceAccountKey_FieldPathSelectorValidNotAfter: 987 for _, v := range fpaov.values.([]*timestamppb.Timestamp) { 988 values = append(values, v) 989 } 990 } 991 return 992 } 993 func (fpaov *ServiceAccountKey_FieldTerminalPathArrayOfValues) AsNameArrayOfValues() ([]*Name, bool) { 994 res, ok := fpaov.values.([]*Name) 995 return res, ok 996 } 997 func (fpaov *ServiceAccountKey_FieldTerminalPathArrayOfValues) AsMetadataArrayOfValues() ([]*meta.Meta, bool) { 998 res, ok := fpaov.values.([]*meta.Meta) 999 return res, ok 1000 } 1001 func (fpaov *ServiceAccountKey_FieldTerminalPathArrayOfValues) AsDisplayNameArrayOfValues() ([]string, bool) { 1002 res, ok := fpaov.values.([]string) 1003 return res, ok 1004 } 1005 func (fpaov *ServiceAccountKey_FieldTerminalPathArrayOfValues) AsDescriptionArrayOfValues() ([]string, bool) { 1006 res, ok := fpaov.values.([]string) 1007 return res, ok 1008 } 1009 func (fpaov *ServiceAccountKey_FieldTerminalPathArrayOfValues) AsPublicKeyDataArrayOfValues() ([]string, bool) { 1010 res, ok := fpaov.values.([]string) 1011 return res, ok 1012 } 1013 func (fpaov *ServiceAccountKey_FieldTerminalPathArrayOfValues) AsPrivateKeyDataArrayOfValues() ([]string, bool) { 1014 res, ok := fpaov.values.([]string) 1015 return res, ok 1016 } 1017 func (fpaov *ServiceAccountKey_FieldTerminalPathArrayOfValues) AsApiKeyArrayOfValues() ([]string, bool) { 1018 res, ok := fpaov.values.([]string) 1019 return res, ok 1020 } 1021 func (fpaov *ServiceAccountKey_FieldTerminalPathArrayOfValues) AsAlgorithmArrayOfValues() ([]ServiceAccountKey_Algorithm, bool) { 1022 res, ok := fpaov.values.([]ServiceAccountKey_Algorithm) 1023 return res, ok 1024 } 1025 func (fpaov *ServiceAccountKey_FieldTerminalPathArrayOfValues) AsValidNotBeforeArrayOfValues() ([]*timestamppb.Timestamp, bool) { 1026 res, ok := fpaov.values.([]*timestamppb.Timestamp) 1027 return res, ok 1028 } 1029 func (fpaov *ServiceAccountKey_FieldTerminalPathArrayOfValues) AsValidNotAfterArrayOfValues() ([]*timestamppb.Timestamp, bool) { 1030 res, ok := fpaov.values.([]*timestamppb.Timestamp) 1031 return res, ok 1032 } 1033 1034 type ServiceAccountKey_FieldSubPathArrayOfValues struct { 1035 ServiceAccountKey_FieldPath 1036 subPathArrayOfValues gotenobject.FieldPathArrayOfValues 1037 } 1038 1039 var _ ServiceAccountKey_FieldPathArrayOfValues = (*ServiceAccountKey_FieldSubPathArrayOfValues)(nil) 1040 1041 func (fpsaov *ServiceAccountKey_FieldSubPathArrayOfValues) GetRawValues() []interface{} { 1042 return fpsaov.subPathArrayOfValues.GetRawValues() 1043 } 1044 func (fpsaov *ServiceAccountKey_FieldSubPathArrayOfValues) AsMetadataPathArrayOfValues() (meta.Meta_FieldPathArrayOfValues, bool) { 1045 res, ok := fpsaov.subPathArrayOfValues.(meta.Meta_FieldPathArrayOfValues) 1046 return res, ok 1047 }