func (m *PrivateGetDepositsResponseResult) MarshalBinary() ([]byte, error) {
	if m == nil {
		return nil, nil
	}
	return swag.WriteJSON(m)
}
MarshalBinary interface implementation
package models
import (
	"strconv"
	strfmt "github.com/go-openapi/strfmt"
	"github.com/go-openapi/errors"
	"github.com/go-openapi/swag"
	"github.com/go-openapi/validate"
)
type PrivateGetDepositsResponse struct {
	Result *PrivateGetDepositsResponseResult `json:"result"`
}
func (m *PrivateGetDepositsResponse) Validate(formats strfmt.Registry) error {
	var res []error
	if err := m.validateResult(formats); err != nil {
		res = append(res, err)
	}
	if len(res) > 0 {
		return errors.CompositeValidationError(res...)
	}
	return nil
}
func (m *PrivateGetDepositsResponse) validateResult(formats strfmt.Registry) error {
	if err := validate.Required("result", "body", m.Result); err != nil {
		return err
	}
	if m.Result != nil {
		if err := m.Result.Validate(formats); err != nil {
			if ve, ok := err.(*errors.Validation); ok {
				return ve.ValidateName("result")
			}
			return err
		}
	}
	return nil
}
func (m *PrivateGetDepositsResponse) MarshalBinary() ([]byte, error) {
	if m == nil {
		return nil, nil
	}
	return swag.WriteJSON(m)
}
func (m *PrivateGetDepositsResponse) UnmarshalBinary(b []byte) error {
	var res PrivateGetDepositsResponse
	if err := swag.ReadJSON(b, &res); err != nil {
		return err
	}
	*m = res
	return nil
}
type PrivateGetDepositsResponseResult struct {
	Count ResultCount `json:"count"`
	Data []*Deposit `json:"data"`
}
func (m *PrivateGetDepositsResponseResult) Validate(formats strfmt.Registry) error {
	var res []error
	if err := m.validateCount(formats); err != nil {
		res = append(res, err)
	}
	if err := m.validateData(formats); err != nil {
		res = append(res, err)
	}
	if len(res) > 0 {
		return errors.CompositeValidationError(res...)
	}
	return nil
}
func (m *PrivateGetDepositsResponseResult) validateCount(formats strfmt.Registry) error {
	if err := m.Count.Validate(formats); err != nil {
		if ve, ok := err.(*errors.Validation); ok {
			return ve.ValidateName("result" + "." + "count")
		}
		return err
	}
	return nil
}
func (m *PrivateGetDepositsResponseResult) validateData(formats strfmt.Registry) error {
	if err := validate.Required("result"+"."+"data", "body", m.Data); err != nil {
		return err
	}
	for i := 0; i < len(m.Data); i++ {
		if swag.IsZero(m.Data[i]) {  
			continue
		}
		if m.Data[i] != nil {
			if err := m.Data[i].Validate(formats); err != nil {
				if ve, ok := err.(*errors.Validation); ok {
					return ve.ValidateName("result" + "." + "data" + "." + strconv.Itoa(i))
				}
				return err
			}
		}
	}
	return nil
}