parent
c7c570fd10
commit
dc1926f9c6
18 changed files with 1837 additions and 126 deletions
|
@ -151,77 +151,3 @@ func (o *PutObjectBody) UnmarshalBinary(b []byte) error {
|
|||
*o = res
|
||||
return nil
|
||||
}
|
||||
|
||||
// PutObjectOKBody put object o k body
|
||||
// Example: {"containerId":"5HZTn5qkRnmgSz9gSrw22CEdPPk6nQhkwf2Mgzyvkikv","objectId":"8N3o7Dtr6T1xteCt6eRwhpmJ7JhME58Hyu1dvaswuTDd"}
|
||||
//
|
||||
// swagger:model PutObjectOKBody
|
||||
type PutObjectOKBody struct {
|
||||
|
||||
// container Id
|
||||
// Required: true
|
||||
ContainerID *string `json:"containerId"`
|
||||
|
||||
// object Id
|
||||
// Required: true
|
||||
ObjectID *string `json:"objectId"`
|
||||
}
|
||||
|
||||
// Validate validates this put object o k body
|
||||
func (o *PutObjectOKBody) Validate(formats strfmt.Registry) error {
|
||||
var res []error
|
||||
|
||||
if err := o.validateContainerID(formats); err != nil {
|
||||
res = append(res, err)
|
||||
}
|
||||
|
||||
if err := o.validateObjectID(formats); err != nil {
|
||||
res = append(res, err)
|
||||
}
|
||||
|
||||
if len(res) > 0 {
|
||||
return errors.CompositeValidationError(res...)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (o *PutObjectOKBody) validateContainerID(formats strfmt.Registry) error {
|
||||
|
||||
if err := validate.Required("putObjectOK"+"."+"containerId", "body", o.ContainerID); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
func (o *PutObjectOKBody) validateObjectID(formats strfmt.Registry) error {
|
||||
|
||||
if err := validate.Required("putObjectOK"+"."+"objectId", "body", o.ObjectID); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
// ContextValidate validates this put object o k body based on context it is used
|
||||
func (o *PutObjectOKBody) ContextValidate(ctx context.Context, formats strfmt.Registry) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
// MarshalBinary interface implementation
|
||||
func (o *PutObjectOKBody) MarshalBinary() ([]byte, error) {
|
||||
if o == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return swag.WriteJSON(o)
|
||||
}
|
||||
|
||||
// UnmarshalBinary interface implementation
|
||||
func (o *PutObjectOKBody) UnmarshalBinary(b []byte) error {
|
||||
var res PutObjectOKBody
|
||||
if err := swag.ReadJSON(b, &res); err != nil {
|
||||
return err
|
||||
}
|
||||
*o = res
|
||||
return nil
|
||||
}
|
||||
|
|
Reference in a new issue