github.com/goharbor/go-client@v0.210.0/pkg/sdk/v2.0/models/authproxy_setting.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  // AuthproxySetting authproxy setting
    16  //
    17  // swagger:model AuthproxySetting
    18  type AuthproxySetting struct {
    19  
    20  	// The fully qualified URI of login endpoint of authproxy, such as 'https://192.168.1.2:8443/login'
    21  	Endpoint string `json:"endpoint,omitempty"`
    22  
    23  	// The certificate to be pinned when connecting auth proxy.
    24  	ServerCertificate string `json:"server_certificate,omitempty"`
    25  
    26  	// The flag to determine whether Harbor can skip search the user/group when adding him as a member.
    27  	SkipSearch bool `json:"skip_search,omitempty"`
    28  
    29  	// The fully qualified URI of token review endpoint of authproxy, such as 'https://192.168.1.2:8443/tokenreview'
    30  	TokenreivewEndpoint string `json:"tokenreivew_endpoint,omitempty"`
    31  
    32  	// The flag to determine whether Harbor should verify the certificate when connecting to the auth proxy.
    33  	VerifyCert bool `json:"verify_cert,omitempty"`
    34  }
    35  
    36  // Validate validates this authproxy setting
    37  func (m *AuthproxySetting) Validate(formats strfmt.Registry) error {
    38  	return nil
    39  }
    40  
    41  // ContextValidate validates this authproxy setting based on context it is used
    42  func (m *AuthproxySetting) ContextValidate(ctx context.Context, formats strfmt.Registry) error {
    43  	return nil
    44  }
    45  
    46  // MarshalBinary interface implementation
    47  func (m *AuthproxySetting) MarshalBinary() ([]byte, error) {
    48  	if m == nil {
    49  		return nil, nil
    50  	}
    51  	return swag.WriteJSON(m)
    52  }
    53  
    54  // UnmarshalBinary interface implementation
    55  func (m *AuthproxySetting) UnmarshalBinary(b []byte) error {
    56  	var res AuthproxySetting
    57  	if err := swag.ReadJSON(b, &res); err != nil {
    58  		return err
    59  	}
    60  	*m = res
    61  	return nil
    62  }