63 lines
1.6 KiB
Go
63 lines
1.6 KiB
Go
|
// Code generated by go-swagger; DO NOT EDIT.
|
||
|
|
||
|
package models
|
||
|
|
||
|
// This file was generated by the swagger tool.
|
||
|
// Editing this file might prove futile when you re-run the swagger generate command
|
||
|
|
||
|
import (
|
||
|
"context"
|
||
|
|
||
|
"github.com/go-openapi/strfmt"
|
||
|
"github.com/go-openapi/swag"
|
||
|
)
|
||
|
|
||
|
// CreatePushMirrorOption CreatePushMirrorOption represents need information to create a push mirror of a repository.
|
||
|
//
|
||
|
// swagger:model CreatePushMirrorOption
|
||
|
type CreatePushMirrorOption struct {
|
||
|
|
||
|
// interval
|
||
|
Interval string `json:"interval,omitempty"`
|
||
|
|
||
|
// remote address
|
||
|
RemoteAddress string `json:"remote_address,omitempty"`
|
||
|
|
||
|
// remote password
|
||
|
RemotePassword string `json:"remote_password,omitempty"`
|
||
|
|
||
|
// remote username
|
||
|
RemoteUsername string `json:"remote_username,omitempty"`
|
||
|
|
||
|
// sync on commit
|
||
|
SyncOnCommit bool `json:"sync_on_commit,omitempty"`
|
||
|
}
|
||
|
|
||
|
// Validate validates this create push mirror option
|
||
|
func (m *CreatePushMirrorOption) Validate(formats strfmt.Registry) error {
|
||
|
return nil
|
||
|
}
|
||
|
|
||
|
// ContextValidate validates this create push mirror option based on context it is used
|
||
|
func (m *CreatePushMirrorOption) ContextValidate(ctx context.Context, formats strfmt.Registry) error {
|
||
|
return nil
|
||
|
}
|
||
|
|
||
|
// MarshalBinary interface implementation
|
||
|
func (m *CreatePushMirrorOption) MarshalBinary() ([]byte, error) {
|
||
|
if m == nil {
|
||
|
return nil, nil
|
||
|
}
|
||
|
return swag.WriteJSON(m)
|
||
|
}
|
||
|
|
||
|
// UnmarshalBinary interface implementation
|
||
|
func (m *CreatePushMirrorOption) UnmarshalBinary(b []byte) error {
|
||
|
var res CreatePushMirrorOption
|
||
|
if err := swag.ReadJSON(b, &res); err != nil {
|
||
|
return err
|
||
|
}
|
||
|
*m = res
|
||
|
return nil
|
||
|
}
|