-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathcertificate_params.go
More file actions
54 lines (49 loc) · 2.16 KB
/
Copy pathcertificate_params.go
File metadata and controls
54 lines (49 loc) · 2.16 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
package controller
import (
"fmt"
)
type CertificateParams struct {
Name *string
Tags *string
StandaloneFile *string
Expiry *int
Ca *string
KeyType *string
DnLocality *string
DnState *string
DnOrg *string
DnOrgUnit *string
DnCountry *string
DnStreet *string
DnPostal *string
ConfirmDelete *string
Export *string
Private *bool
CertFile *string
KeyFile *string
}
func NewCertificateParams() *CertificateParams {
return new(CertificateParams)
}
func (params *CertificateParams) ValidateName(required bool) error {
if required && *params.Name == "" {
return fmt.Errorf("name cannot be empty")
}
return nil
}
func (params *CertificateParams) ValidateStandalone(required bool) error { return nil }
func (params *CertificateParams) ValidateTags(required bool) error { return nil }
func (params *CertificateParams) ValidateExpiry(required bool) error { return nil }
func (params *CertificateParams) ValidateKeyType(required bool) error { return nil }
func (params *CertificateParams) ValidateDnLocality(required bool) error { return nil }
func (params *CertificateParams) ValidateDnState(required bool) error { return nil }
func (params *CertificateParams) ValidateDnOrg(required bool) error { return nil }
func (params *CertificateParams) ValidateDnOrgUnit(required bool) error { return nil }
func (params *CertificateParams) ValidateDnCountry(required bool) error { return nil }
func (params *CertificateParams) ValidateDnStreet(required bool) error { return nil }
func (params *CertificateParams) ValidateDnPostal(required bool) error { return nil }
func (params *CertificateParams) ValidateConfirmDelete(required bool) error { return nil }
func (params *CertificateParams) ValidateExport(required bool) error { return nil }
func (params *CertificateParams) ValidatePrivate(required bool) error { return nil }
func (params *CertificateParams) ValidateCertFile(required bool) error { return nil }
func (params *CertificateParams) ValidateKeyFile(required bool) error { return nil }