github.com/vmware/govmomi@v0.51.0/sms/types/enum.go (about) 1 // © Broadcom. All Rights Reserved. 2 // The term “Broadcom” refers to Broadcom Inc. and/or its subsidiaries. 3 // SPDX-License-Identifier: Apache-2.0 4 5 package types 6 7 import ( 8 "reflect" 9 10 "github.com/vmware/govmomi/vim25/types" 11 ) 12 13 type AlarmType string 14 15 const ( 16 AlarmTypeSpaceCapacityAlarm = AlarmType("SpaceCapacityAlarm") 17 AlarmTypeCapabilityAlarm = AlarmType("CapabilityAlarm") 18 AlarmTypeStorageObjectAlarm = AlarmType("StorageObjectAlarm") 19 AlarmTypeObjectAlarm = AlarmType("ObjectAlarm") 20 AlarmTypeComplianceAlarm = AlarmType("ComplianceAlarm") 21 AlarmTypeManageabilityAlarm = AlarmType("ManageabilityAlarm") 22 AlarmTypeReplicationAlarm = AlarmType("ReplicationAlarm") 23 AlarmTypeCertificateAlarm = AlarmType("CertificateAlarm") 24 ) 25 26 func (e AlarmType) Values() []AlarmType { 27 return []AlarmType{ 28 AlarmTypeSpaceCapacityAlarm, 29 AlarmTypeCapabilityAlarm, 30 AlarmTypeStorageObjectAlarm, 31 AlarmTypeObjectAlarm, 32 AlarmTypeComplianceAlarm, 33 AlarmTypeManageabilityAlarm, 34 AlarmTypeReplicationAlarm, 35 AlarmTypeCertificateAlarm, 36 } 37 } 38 39 func (e AlarmType) Strings() []string { 40 return types.EnumValuesAsStrings(e.Values()) 41 } 42 43 func init() { 44 types.Add("sms:AlarmType", reflect.TypeOf((*AlarmType)(nil)).Elem()) 45 } 46 47 // List of possible BackingStoragePool types 48 type BackingStoragePoolType string 49 50 const ( 51 BackingStoragePoolTypeThinProvisioningPool = BackingStoragePoolType("thinProvisioningPool") 52 BackingStoragePoolTypeDeduplicationPool = BackingStoragePoolType("deduplicationPool") 53 BackingStoragePoolTypeThinAndDeduplicationCombinedPool = BackingStoragePoolType("thinAndDeduplicationCombinedPool") 54 ) 55 56 func (e BackingStoragePoolType) Values() []BackingStoragePoolType { 57 return []BackingStoragePoolType{ 58 BackingStoragePoolTypeThinProvisioningPool, 59 BackingStoragePoolTypeDeduplicationPool, 60 BackingStoragePoolTypeThinAndDeduplicationCombinedPool, 61 } 62 } 63 64 func (e BackingStoragePoolType) Strings() []string { 65 return types.EnumValuesAsStrings(e.Values()) 66 } 67 68 func init() { 69 types.Add("sms:BackingStoragePoolType", reflect.TypeOf((*BackingStoragePoolType)(nil)).Elem()) 70 } 71 72 // List of possible block device interfaces 73 type BlockDeviceInterface string 74 75 const ( 76 BlockDeviceInterfaceFc = BlockDeviceInterface("fc") 77 BlockDeviceInterfaceIscsi = BlockDeviceInterface("iscsi") 78 BlockDeviceInterfaceFcoe = BlockDeviceInterface("fcoe") 79 BlockDeviceInterfaceOtherBlock = BlockDeviceInterface("otherBlock") 80 ) 81 82 func (e BlockDeviceInterface) Values() []BlockDeviceInterface { 83 return []BlockDeviceInterface{ 84 BlockDeviceInterfaceFc, 85 BlockDeviceInterfaceIscsi, 86 BlockDeviceInterfaceFcoe, 87 BlockDeviceInterfaceOtherBlock, 88 } 89 } 90 91 func (e BlockDeviceInterface) Strings() []string { 92 return types.EnumValuesAsStrings(e.Values()) 93 } 94 95 func init() { 96 types.Add("sms:BlockDeviceInterface", reflect.TypeOf((*BlockDeviceInterface)(nil)).Elem()) 97 } 98 99 // Types of entities supported by the service. 100 type EntityReferenceEntityType string 101 102 const ( 103 EntityReferenceEntityTypeDatacenter = EntityReferenceEntityType("datacenter") 104 EntityReferenceEntityTypeResourcePool = EntityReferenceEntityType("resourcePool") 105 EntityReferenceEntityTypeStoragePod = EntityReferenceEntityType("storagePod") 106 EntityReferenceEntityTypeCluster = EntityReferenceEntityType("cluster") 107 EntityReferenceEntityTypeVm = EntityReferenceEntityType("vm") 108 EntityReferenceEntityTypeDatastore = EntityReferenceEntityType("datastore") 109 EntityReferenceEntityTypeHost = EntityReferenceEntityType("host") 110 EntityReferenceEntityTypeVmFile = EntityReferenceEntityType("vmFile") 111 EntityReferenceEntityTypeScsiPath = EntityReferenceEntityType("scsiPath") 112 EntityReferenceEntityTypeScsiTarget = EntityReferenceEntityType("scsiTarget") 113 EntityReferenceEntityTypeScsiVolume = EntityReferenceEntityType("scsiVolume") 114 EntityReferenceEntityTypeScsiAdapter = EntityReferenceEntityType("scsiAdapter") 115 EntityReferenceEntityTypeNasMount = EntityReferenceEntityType("nasMount") 116 ) 117 118 func (e EntityReferenceEntityType) Values() []EntityReferenceEntityType { 119 return []EntityReferenceEntityType{ 120 EntityReferenceEntityTypeDatacenter, 121 EntityReferenceEntityTypeResourcePool, 122 EntityReferenceEntityTypeStoragePod, 123 EntityReferenceEntityTypeCluster, 124 EntityReferenceEntityTypeVm, 125 EntityReferenceEntityTypeDatastore, 126 EntityReferenceEntityTypeHost, 127 EntityReferenceEntityTypeVmFile, 128 EntityReferenceEntityTypeScsiPath, 129 EntityReferenceEntityTypeScsiTarget, 130 EntityReferenceEntityTypeScsiVolume, 131 EntityReferenceEntityTypeScsiAdapter, 132 EntityReferenceEntityTypeNasMount, 133 } 134 } 135 136 func (e EntityReferenceEntityType) Strings() []string { 137 return types.EnumValuesAsStrings(e.Values()) 138 } 139 140 func init() { 141 types.Add("sms:EntityReferenceEntityType", reflect.TypeOf((*EntityReferenceEntityType)(nil)).Elem()) 142 } 143 144 // List of possible file system interfaces 145 type FileSystemInterface string 146 147 const ( 148 FileSystemInterfaceNfs = FileSystemInterface("nfs") 149 FileSystemInterfaceOtherFileSystem = FileSystemInterface("otherFileSystem") 150 ) 151 152 func (e FileSystemInterface) Values() []FileSystemInterface { 153 return []FileSystemInterface{ 154 FileSystemInterfaceNfs, 155 FileSystemInterfaceOtherFileSystem, 156 } 157 } 158 159 func (e FileSystemInterface) Strings() []string { 160 return types.EnumValuesAsStrings(e.Values()) 161 } 162 163 func init() { 164 types.Add("sms:FileSystemInterface", reflect.TypeOf((*FileSystemInterface)(nil)).Elem()) 165 } 166 167 type FileSystemInterfaceVersion string 168 169 const ( 170 FileSystemInterfaceVersionNFSV3_0 = FileSystemInterfaceVersion("NFSV3_0") 171 ) 172 173 func (e FileSystemInterfaceVersion) Values() []FileSystemInterfaceVersion { 174 return []FileSystemInterfaceVersion{ 175 FileSystemInterfaceVersionNFSV3_0, 176 } 177 } 178 179 func (e FileSystemInterfaceVersion) Strings() []string { 180 return types.EnumValuesAsStrings(e.Values()) 181 } 182 183 func init() { 184 types.Add("sms:FileSystemInterfaceVersion", reflect.TypeOf((*FileSystemInterfaceVersion)(nil)).Elem()) 185 } 186 187 type ManagedObjectTypes string 188 189 const ( 190 ManagedObjectTypesSmsServiceInstance = ManagedObjectTypes("SmsServiceInstance") 191 ManagedObjectTypesSmsStorageManager = ManagedObjectTypes("SmsStorageManager") 192 ManagedObjectTypesSmsTask = ManagedObjectTypes("SmsTask") 193 ManagedObjectTypesSmsSessionManager = ManagedObjectTypes("SmsSessionManager") 194 ManagedObjectTypesSmsProvider = ManagedObjectTypes("SmsProvider") 195 ManagedObjectTypesVasaProvider = ManagedObjectTypes("VasaProvider") 196 ) 197 198 func (e ManagedObjectTypes) Values() []ManagedObjectTypes { 199 return []ManagedObjectTypes{ 200 ManagedObjectTypesSmsServiceInstance, 201 ManagedObjectTypesSmsStorageManager, 202 ManagedObjectTypesSmsTask, 203 ManagedObjectTypesSmsSessionManager, 204 ManagedObjectTypesSmsProvider, 205 ManagedObjectTypesVasaProvider, 206 } 207 } 208 209 func (e ManagedObjectTypes) Strings() []string { 210 return types.EnumValuesAsStrings(e.Values()) 211 } 212 213 func init() { 214 types.Add("sms:ManagedObjectTypes", reflect.TypeOf((*ManagedObjectTypes)(nil)).Elem()) 215 } 216 217 // Profiles supported by VASA Provider. 218 type ProviderProfile string 219 220 const ( 221 // PBM profile 222 ProviderProfileProfileBasedManagement = ProviderProfile("ProfileBasedManagement") 223 // Replication profile 224 ProviderProfileReplication = ProviderProfile("Replication") 225 ) 226 227 func (e ProviderProfile) Values() []ProviderProfile { 228 return []ProviderProfile{ 229 ProviderProfileProfileBasedManagement, 230 ProviderProfileReplication, 231 } 232 } 233 234 func (e ProviderProfile) Strings() []string { 235 return types.EnumValuesAsStrings(e.Values()) 236 } 237 238 func init() { 239 types.Add("sms:ProviderProfile", reflect.TypeOf((*ProviderProfile)(nil)).Elem()) 240 } 241 242 // State of the replication group at the site of the query. 243 // 244 // A replication group 245 // may be in different states at the source site and each of the target sites. 246 // Note that this state does not capture the health of the replication link. If 247 // necessary, that can be an additional attribute. 248 type ReplicationReplicationState string 249 250 const ( 251 // Replication Source 252 ReplicationReplicationStateSOURCE = ReplicationReplicationState("SOURCE") 253 // Replication target 254 ReplicationReplicationStateTARGET = ReplicationReplicationState("TARGET") 255 // The group failed over at this site of the query. 256 // 257 // It has not yet been made 258 // as a source of replication. 259 ReplicationReplicationStateFAILEDOVER = ReplicationReplicationState("FAILEDOVER") 260 // The group is InTest. 261 // 262 // The testFailover devices list will be available from 263 // the `TargetGroupMemberInfo` 264 ReplicationReplicationStateINTEST = ReplicationReplicationState("INTEST") 265 // Remote group was failed over, and this site is neither the source nor the 266 // target. 267 ReplicationReplicationStateREMOTE_FAILEDOVER = ReplicationReplicationState("REMOTE_FAILEDOVER") 268 ) 269 270 func (e ReplicationReplicationState) Values() []ReplicationReplicationState { 271 return []ReplicationReplicationState{ 272 ReplicationReplicationStateSOURCE, 273 ReplicationReplicationStateTARGET, 274 ReplicationReplicationStateFAILEDOVER, 275 ReplicationReplicationStateINTEST, 276 ReplicationReplicationStateREMOTE_FAILEDOVER, 277 } 278 } 279 280 func (e ReplicationReplicationState) Strings() []string { 281 return types.EnumValuesAsStrings(e.Values()) 282 } 283 284 func init() { 285 types.Add("sms:ReplicationReplicationState", reflect.TypeOf((*ReplicationReplicationState)(nil)).Elem()) 286 } 287 288 // Enumeration of the supported Alarm Status values 289 type SmsAlarmStatus string 290 291 const ( 292 SmsAlarmStatusRed = SmsAlarmStatus("Red") 293 SmsAlarmStatusGreen = SmsAlarmStatus("Green") 294 SmsAlarmStatusYellow = SmsAlarmStatus("Yellow") 295 ) 296 297 func (e SmsAlarmStatus) Values() []SmsAlarmStatus { 298 return []SmsAlarmStatus{ 299 SmsAlarmStatusRed, 300 SmsAlarmStatusGreen, 301 SmsAlarmStatusYellow, 302 } 303 } 304 305 func (e SmsAlarmStatus) Strings() []string { 306 return types.EnumValuesAsStrings(e.Values()) 307 } 308 309 func init() { 310 types.Add("sms:SmsAlarmStatus", reflect.TypeOf((*SmsAlarmStatus)(nil)).Elem()) 311 } 312 313 // Enumeration of the supported Entity Type values. 314 type SmsEntityType string 315 316 const ( 317 SmsEntityTypeStorageArrayEntity = SmsEntityType("StorageArrayEntity") 318 SmsEntityTypeStorageProcessorEntity = SmsEntityType("StorageProcessorEntity") 319 SmsEntityTypeStoragePortEntity = SmsEntityType("StoragePortEntity") 320 SmsEntityTypeStorageLunEntity = SmsEntityType("StorageLunEntity") 321 SmsEntityTypeStorageFileSystemEntity = SmsEntityType("StorageFileSystemEntity") 322 SmsEntityTypeStorageCapabilityEntity = SmsEntityType("StorageCapabilityEntity") 323 SmsEntityTypeCapabilitySchemaEntity = SmsEntityType("CapabilitySchemaEntity") 324 SmsEntityTypeCapabilityProfileEntity = SmsEntityType("CapabilityProfileEntity") 325 SmsEntityTypeDefaultProfileEntity = SmsEntityType("DefaultProfileEntity") 326 SmsEntityTypeResourceAssociationEntity = SmsEntityType("ResourceAssociationEntity") 327 SmsEntityTypeStorageContainerEntity = SmsEntityType("StorageContainerEntity") 328 SmsEntityTypeStorageObjectEntity = SmsEntityType("StorageObjectEntity") 329 SmsEntityTypeMessageCatalogEntity = SmsEntityType("MessageCatalogEntity") 330 SmsEntityTypeProtocolEndpointEntity = SmsEntityType("ProtocolEndpointEntity") 331 SmsEntityTypeVirtualVolumeInfoEntity = SmsEntityType("VirtualVolumeInfoEntity") 332 SmsEntityTypeBackingStoragePoolEntity = SmsEntityType("BackingStoragePoolEntity") 333 SmsEntityTypeFaultDomainEntity = SmsEntityType("FaultDomainEntity") 334 SmsEntityTypeReplicationGroupEntity = SmsEntityType("ReplicationGroupEntity") 335 ) 336 337 func (e SmsEntityType) Values() []SmsEntityType { 338 return []SmsEntityType{ 339 SmsEntityTypeStorageArrayEntity, 340 SmsEntityTypeStorageProcessorEntity, 341 SmsEntityTypeStoragePortEntity, 342 SmsEntityTypeStorageLunEntity, 343 SmsEntityTypeStorageFileSystemEntity, 344 SmsEntityTypeStorageCapabilityEntity, 345 SmsEntityTypeCapabilitySchemaEntity, 346 SmsEntityTypeCapabilityProfileEntity, 347 SmsEntityTypeDefaultProfileEntity, 348 SmsEntityTypeResourceAssociationEntity, 349 SmsEntityTypeStorageContainerEntity, 350 SmsEntityTypeStorageObjectEntity, 351 SmsEntityTypeMessageCatalogEntity, 352 SmsEntityTypeProtocolEndpointEntity, 353 SmsEntityTypeVirtualVolumeInfoEntity, 354 SmsEntityTypeBackingStoragePoolEntity, 355 SmsEntityTypeFaultDomainEntity, 356 SmsEntityTypeReplicationGroupEntity, 357 } 358 } 359 360 func (e SmsEntityType) Strings() []string { 361 return types.EnumValuesAsStrings(e.Values()) 362 } 363 364 func init() { 365 types.Add("sms:SmsEntityType", reflect.TypeOf((*SmsEntityType)(nil)).Elem()) 366 } 367 368 // List of possible states of a task. 369 type SmsTaskState string 370 371 const ( 372 // Task is put in the queue. 373 SmsTaskStateQueued = SmsTaskState("queued") 374 // Task is currently running. 375 SmsTaskStateRunning = SmsTaskState("running") 376 // Task has completed. 377 SmsTaskStateSuccess = SmsTaskState("success") 378 // Task has encountered an error or has been canceled. 379 SmsTaskStateError = SmsTaskState("error") 380 ) 381 382 func (e SmsTaskState) Values() []SmsTaskState { 383 return []SmsTaskState{ 384 SmsTaskStateQueued, 385 SmsTaskStateRunning, 386 SmsTaskStateSuccess, 387 SmsTaskStateError, 388 } 389 } 390 391 func (e SmsTaskState) Strings() []string { 392 return types.EnumValuesAsStrings(e.Values()) 393 } 394 395 func init() { 396 types.Add("sms:SmsTaskState", reflect.TypeOf((*SmsTaskState)(nil)).Elem()) 397 } 398 399 // List of supported VVOL Container types 400 type StorageContainerVvolContainerTypeEnum string 401 402 const ( 403 StorageContainerVvolContainerTypeEnumNFS = StorageContainerVvolContainerTypeEnum("NFS") 404 StorageContainerVvolContainerTypeEnumNFS4x = StorageContainerVvolContainerTypeEnum("NFS4x") 405 StorageContainerVvolContainerTypeEnumSCSI = StorageContainerVvolContainerTypeEnum("SCSI") 406 StorageContainerVvolContainerTypeEnumNVMe = StorageContainerVvolContainerTypeEnum("NVMe") 407 ) 408 409 func (e StorageContainerVvolContainerTypeEnum) Values() []StorageContainerVvolContainerTypeEnum { 410 return []StorageContainerVvolContainerTypeEnum{ 411 StorageContainerVvolContainerTypeEnumNFS, 412 StorageContainerVvolContainerTypeEnumNFS4x, 413 StorageContainerVvolContainerTypeEnumSCSI, 414 StorageContainerVvolContainerTypeEnumNVMe, 415 } 416 } 417 418 func (e StorageContainerVvolContainerTypeEnum) Strings() []string { 419 return types.EnumValuesAsStrings(e.Values()) 420 } 421 422 func init() { 423 types.Add("sms:StorageContainerVvolContainerTypeEnum", reflect.TypeOf((*StorageContainerVvolContainerTypeEnum)(nil)).Elem()) 424 } 425 426 // List of possible values for thin provisioning status alarm. 427 type ThinProvisioningStatus string 428 429 const ( 430 ThinProvisioningStatusRED = ThinProvisioningStatus("RED") 431 ThinProvisioningStatusYELLOW = ThinProvisioningStatus("YELLOW") 432 ThinProvisioningStatusGREEN = ThinProvisioningStatus("GREEN") 433 ) 434 435 func (e ThinProvisioningStatus) Values() []ThinProvisioningStatus { 436 return []ThinProvisioningStatus{ 437 ThinProvisioningStatusRED, 438 ThinProvisioningStatusYELLOW, 439 ThinProvisioningStatusGREEN, 440 } 441 } 442 443 func (e ThinProvisioningStatus) Strings() []string { 444 return types.EnumValuesAsStrings(e.Values()) 445 } 446 447 func init() { 448 types.Add("sms:ThinProvisioningStatus", reflect.TypeOf((*ThinProvisioningStatus)(nil)).Elem()) 449 } 450 451 // VASA provider authentication type. 452 type VasaAuthenticationType string 453 454 const ( 455 // Login using SAML token. 456 VasaAuthenticationTypeLoginByToken = VasaAuthenticationType("LoginByToken") 457 // Use id of an existing session that has logged-in from somewhere else. 458 VasaAuthenticationTypeUseSessionId = VasaAuthenticationType("UseSessionId") 459 ) 460 461 func (e VasaAuthenticationType) Values() []VasaAuthenticationType { 462 return []VasaAuthenticationType{ 463 VasaAuthenticationTypeLoginByToken, 464 VasaAuthenticationTypeUseSessionId, 465 } 466 } 467 468 func (e VasaAuthenticationType) Strings() []string { 469 return types.EnumValuesAsStrings(e.Values()) 470 } 471 472 func init() { 473 types.Add("sms:VasaAuthenticationType", reflect.TypeOf((*VasaAuthenticationType)(nil)).Elem()) 474 } 475 476 // List of possible VASA profiles supported by Storage Array 477 type VasaProfile string 478 479 const ( 480 // Block device profile 481 VasaProfileBlockDevice = VasaProfile("blockDevice") 482 // File system profile 483 VasaProfileFileSystem = VasaProfile("fileSystem") 484 // Storage capability profile 485 VasaProfileCapability = VasaProfile("capability") 486 // Policy profile 487 VasaProfilePolicy = VasaProfile("policy") 488 // Object based storage profile 489 VasaProfileObject = VasaProfile("object") 490 // IO Statistics profile 491 VasaProfileStatistics = VasaProfile("statistics") 492 // Storage DRS specific block device profile 493 VasaProfileStorageDrsBlockDevice = VasaProfile("storageDrsBlockDevice") 494 // Storage DRS specific file system profile 495 VasaProfileStorageDrsFileSystem = VasaProfile("storageDrsFileSystem") 496 ) 497 498 func (e VasaProfile) Values() []VasaProfile { 499 return []VasaProfile{ 500 VasaProfileBlockDevice, 501 VasaProfileFileSystem, 502 VasaProfileCapability, 503 VasaProfilePolicy, 504 VasaProfileObject, 505 VasaProfileStatistics, 506 VasaProfileStorageDrsBlockDevice, 507 VasaProfileStorageDrsFileSystem, 508 } 509 } 510 511 func (e VasaProfile) Strings() []string { 512 return types.EnumValuesAsStrings(e.Values()) 513 } 514 515 func init() { 516 types.Add("sms:VasaProfile", reflect.TypeOf((*VasaProfile)(nil)).Elem()) 517 } 518 519 // The status of the provider certificate 520 type VasaProviderCertificateStatus string 521 522 const ( 523 // Provider certificate is valid. 524 VasaProviderCertificateStatusValid = VasaProviderCertificateStatus("valid") 525 // Provider certificate is within the soft limit threshold. 526 VasaProviderCertificateStatusExpirySoftLimitReached = VasaProviderCertificateStatus("expirySoftLimitReached") 527 // Provider certificate is within the hard limit threshold. 528 VasaProviderCertificateStatusExpiryHardLimitReached = VasaProviderCertificateStatus("expiryHardLimitReached") 529 // Provider certificate has expired. 530 VasaProviderCertificateStatusExpired = VasaProviderCertificateStatus("expired") 531 // Provider certificate is revoked, malformed or missing. 532 VasaProviderCertificateStatusInvalid = VasaProviderCertificateStatus("invalid") 533 ) 534 535 func (e VasaProviderCertificateStatus) Values() []VasaProviderCertificateStatus { 536 return []VasaProviderCertificateStatus{ 537 VasaProviderCertificateStatusValid, 538 VasaProviderCertificateStatusExpirySoftLimitReached, 539 VasaProviderCertificateStatusExpiryHardLimitReached, 540 VasaProviderCertificateStatusExpired, 541 VasaProviderCertificateStatusInvalid, 542 } 543 } 544 545 func (e VasaProviderCertificateStatus) Strings() []string { 546 return types.EnumValuesAsStrings(e.Values()) 547 } 548 549 func init() { 550 types.Add("sms:VasaProviderCertificateStatus", reflect.TypeOf((*VasaProviderCertificateStatus)(nil)).Elem()) 551 } 552 553 // Deprecated as of SMS API 3.0, use `VasaProfile_enum`. 554 // 555 // Profiles supported by VASA Provider. 556 type VasaProviderProfile string 557 558 const ( 559 // Block device profile 560 VasaProviderProfileBlockDevice = VasaProviderProfile("blockDevice") 561 // File system profile 562 VasaProviderProfileFileSystem = VasaProviderProfile("fileSystem") 563 // Storage capability profile 564 VasaProviderProfileCapability = VasaProviderProfile("capability") 565 ) 566 567 func (e VasaProviderProfile) Values() []VasaProviderProfile { 568 return []VasaProviderProfile{ 569 VasaProviderProfileBlockDevice, 570 VasaProviderProfileFileSystem, 571 VasaProviderProfileCapability, 572 } 573 } 574 575 func (e VasaProviderProfile) Strings() []string { 576 return types.EnumValuesAsStrings(e.Values()) 577 } 578 579 func init() { 580 types.Add("sms:VasaProviderProfile", reflect.TypeOf((*VasaProviderProfile)(nil)).Elem()) 581 } 582 583 // The operational state of VASA Provider. 584 type VasaProviderStatus string 585 586 const ( 587 // VASA Provider is operating correctly. 588 VasaProviderStatusOnline = VasaProviderStatus("online") 589 // VASA Provider is not responding, e.g. 590 // 591 // communication error due to temporary 592 // network outage. SMS keeps polling the provider in this state. 593 VasaProviderStatusOffline = VasaProviderStatus("offline") 594 // VASA Provider is connected, but sync operation failed. 595 VasaProviderStatusSyncError = VasaProviderStatus("syncError") 596 // Deprecated as of SMS API 4.0, this status is deprecated. 597 // 598 // VASA Provider is unreachable. 599 VasaProviderStatusUnknown = VasaProviderStatus("unknown") 600 // VASA Provider is connected, but has not triggered sync operation. 601 VasaProviderStatusConnected = VasaProviderStatus("connected") 602 // VASA Provider is disconnected, e.g. 603 // 604 // failed to establish a valid 605 // SSL connection to the provider. SMS stops communication with the 606 // provider in this state. The user can reconnect to the provider by invoking 607 // `VasaProvider.VasaProviderReconnect_Task`. 608 VasaProviderStatusDisconnected = VasaProviderStatus("disconnected") 609 ) 610 611 func (e VasaProviderStatus) Values() []VasaProviderStatus { 612 return []VasaProviderStatus{ 613 VasaProviderStatusOnline, 614 VasaProviderStatusOffline, 615 VasaProviderStatusSyncError, 616 VasaProviderStatusUnknown, 617 VasaProviderStatusConnected, 618 VasaProviderStatusDisconnected, 619 } 620 } 621 622 func (e VasaProviderStatus) Strings() []string { 623 return types.EnumValuesAsStrings(e.Values()) 624 } 625 626 func init() { 627 types.Add("sms:VasaProviderStatus", reflect.TypeOf((*VasaProviderStatus)(nil)).Elem()) 628 } 629 630 // A Category to indicate whether provider is of internal or external category. 631 // 632 // This classification can help selectively enable few administrative functions 633 // such as say unregistration of a provider. 634 type VpCategory string 635 636 const ( 637 // An internal provider category indicates the set of providers such as IOFILTERS and VSAN. 638 VpCategoryInternal = VpCategory("internal") 639 // An external provider category indicates the set of providers are external and not belong 640 // to say either of IOFILTERS or VSAN category. 641 VpCategoryExternal = VpCategory("external") 642 ) 643 644 func (e VpCategory) Values() []VpCategory { 645 return []VpCategory{ 646 VpCategoryInternal, 647 VpCategoryExternal, 648 } 649 } 650 651 func (e VpCategory) Strings() []string { 652 return types.EnumValuesAsStrings(e.Values()) 653 } 654 655 func init() { 656 types.Add("sms:VpCategory", reflect.TypeOf((*VpCategory)(nil)).Elem()) 657 } 658 659 // VASA Provider type. 660 type VpType string 661 662 const ( 663 // Persistence provider. 664 VpTypePERSISTENCE = VpType("PERSISTENCE") 665 // DataService provider. 666 // 667 // No storage supported for this type of provider. 668 VpTypeDATASERVICE = VpType("DATASERVICE") 669 // Type is unknown. 670 // 671 // VASA provider type can be UNKNOWN when it is undergoing sync operation. 672 VpTypeUNKNOWN = VpType("UNKNOWN") 673 ) 674 675 func (e VpType) Values() []VpType { 676 return []VpType{ 677 VpTypePERSISTENCE, 678 VpTypeDATASERVICE, 679 VpTypeUNKNOWN, 680 } 681 } 682 683 func (e VpType) Strings() []string { 684 return types.EnumValuesAsStrings(e.Values()) 685 } 686 687 func init() { 688 types.Add("sms:VpType", reflect.TypeOf((*VpType)(nil)).Elem()) 689 }