mirror of
https://github.com/edgelesssys/constellation.git
synced 2025-01-12 07:59:29 -05:00
Regenerate cloudprovider strings
Signed-off-by: Daniel Weiße <dw@edgeless.systems>
This commit is contained in:
parent
423e29e3ab
commit
f2305b3ce6
@ -2,7 +2,7 @@ package cloudprovider
|
||||
|
||||
import "strings"
|
||||
|
||||
//go:generate stringer -type=CloudProvider
|
||||
//go:generate stringer -type=Provider
|
||||
|
||||
// Provider is cloud provider used by the CLI.
|
||||
type Provider uint32
|
||||
@ -12,6 +12,7 @@ const (
|
||||
AWS
|
||||
Azure
|
||||
GCP
|
||||
QEMU
|
||||
)
|
||||
|
||||
// FromString returns cloud provider from string.
|
||||
@ -24,6 +25,8 @@ func FromString(s string) Provider {
|
||||
return Azure
|
||||
case "gcp":
|
||||
return GCP
|
||||
case "qemu":
|
||||
return QEMU
|
||||
default:
|
||||
return Unknown
|
||||
}
|
||||
|
@ -1,26 +0,0 @@
|
||||
// Code generated by "stringer -type=CloudProvider"; DO NOT EDIT.
|
||||
|
||||
package cloudprovider
|
||||
|
||||
import "strconv"
|
||||
|
||||
func _() {
|
||||
// An "invalid array index" compiler error signifies that the constant values have changed.
|
||||
// Re-run the stringer command to generate them again.
|
||||
var x [1]struct{}
|
||||
_ = x[Unknown-0]
|
||||
_ = x[AWS-1]
|
||||
_ = x[Azure-2]
|
||||
_ = x[GCP-3]
|
||||
}
|
||||
|
||||
const _CloudProvider_name = "UnknownAWSAzureGCP"
|
||||
|
||||
var _CloudProvider_index = [...]uint8{0, 7, 10, 15, 18}
|
||||
|
||||
func (i Provider) String() string {
|
||||
if i >= Provider(len(_CloudProvider_index)-1) {
|
||||
return "CloudProvider(" + strconv.FormatInt(int64(i), 10) + ")"
|
||||
}
|
||||
return _CloudProvider_name[_CloudProvider_index[i]:_CloudProvider_index[i+1]]
|
||||
}
|
27
cli/cloudprovider/provider_string.go
Normal file
27
cli/cloudprovider/provider_string.go
Normal file
@ -0,0 +1,27 @@
|
||||
// Code generated by "stringer -type=Provider"; DO NOT EDIT.
|
||||
|
||||
package cloudprovider
|
||||
|
||||
import "strconv"
|
||||
|
||||
func _() {
|
||||
// An "invalid array index" compiler error signifies that the constant values have changed.
|
||||
// Re-run the stringer command to generate them again.
|
||||
var x [1]struct{}
|
||||
_ = x[Unknown-0]
|
||||
_ = x[AWS-1]
|
||||
_ = x[Azure-2]
|
||||
_ = x[GCP-3]
|
||||
_ = x[QEMU-4]
|
||||
}
|
||||
|
||||
const _Provider_name = "UnknownAWSAzureGCPQEMU"
|
||||
|
||||
var _Provider_index = [...]uint8{0, 7, 10, 15, 18, 22}
|
||||
|
||||
func (i Provider) String() string {
|
||||
if i >= Provider(len(_Provider_index)-1) {
|
||||
return "Provider(" + strconv.FormatInt(int64(i), 10) + ")"
|
||||
}
|
||||
return _Provider_name[_Provider_index[i]:_Provider_index[i+1]]
|
||||
}
|
Loading…
Reference in New Issue
Block a user