github.com/goharbor/go-client@v0.210.0/pkg/sdk/v2.0/models/ldap_conf.go (about) 1 // Code generated by go-swagger; DO NOT EDIT. 2 3 package models 4 5 // This file was generated by the swagger tool. 6 // Editing this file might prove futile when you re-run the swagger generate command 7 8 import ( 9 "context" 10 11 "github.com/go-openapi/strfmt" 12 "github.com/go-openapi/swag" 13 ) 14 15 // LdapConf The ldap configure properties 16 // 17 // swagger:model LdapConf 18 type LdapConf struct { 19 20 // The base dn of ldap service. 21 LdapBaseDn string `json:"ldap_base_dn,omitempty"` 22 23 // The connect timeout of ldap service(second). 24 LdapConnectionTimeout int64 `json:"ldap_connection_timeout,omitempty"` 25 26 // The serach filter of ldap service. 27 LdapFilter string `json:"ldap_filter,omitempty"` 28 29 // The serach scope of ldap service. 30 LdapScope int64 `json:"ldap_scope,omitempty"` 31 32 // The search dn of ldap service. 33 LdapSearchDn string `json:"ldap_search_dn,omitempty"` 34 35 // The search password of ldap service. 36 LdapSearchPassword string `json:"ldap_search_password,omitempty"` 37 38 // The serach uid from ldap service attributes. 39 LdapUID string `json:"ldap_uid,omitempty"` 40 41 // The url of ldap service. 42 LdapURL string `json:"ldap_url,omitempty"` 43 44 // Verify Ldap server certificate. 45 LdapVerifyCert bool `json:"ldap_verify_cert,omitempty"` 46 } 47 48 // Validate validates this ldap conf 49 func (m *LdapConf) Validate(formats strfmt.Registry) error { 50 return nil 51 } 52 53 // ContextValidate validates this ldap conf based on context it is used 54 func (m *LdapConf) ContextValidate(ctx context.Context, formats strfmt.Registry) error { 55 return nil 56 } 57 58 // MarshalBinary interface implementation 59 func (m *LdapConf) MarshalBinary() ([]byte, error) { 60 if m == nil { 61 return nil, nil 62 } 63 return swag.WriteJSON(m) 64 } 65 66 // UnmarshalBinary interface implementation 67 func (m *LdapConf) UnmarshalBinary(b []byte) error { 68 var res LdapConf 69 if err := swag.ReadJSON(b, &res); err != nil { 70 return err 71 } 72 *m = res 73 return nil 74 }