func (m *IdmACL) UnmarshalBinary(b []byte) error {
	var res IdmACL
	if err := swag.ReadJSON(b, &res); err != nil {
		return err
	}
	*m = res
	return nil
}
UnmarshalBinary interface implementation
package models
import (
	strfmt "github.com/go-openapi/strfmt"
	"github.com/go-openapi/errors"
	"github.com/go-openapi/swag"
)
type IdmACL struct {
	Action *IdmACLAction `json:"Action,omitempty"`
	ID string `json:"ID,omitempty"`
	NodeID string `json:"NodeID,omitempty"`
	RoleID string `json:"RoleID,omitempty"`
	WorkspaceID string `json:"WorkspaceID,omitempty"`
}
func (m *IdmACL) Validate(formats strfmt.Registry) error {
	var res []error
	if err := m.validateAction(formats); err != nil {
		res = append(res, err)
	}
	if len(res) > 0 {
		return errors.CompositeValidationError(res...)
	}
	return nil
}
func (m *IdmACL) validateAction(formats strfmt.Registry) error {
	if swag.IsZero(m.Action) {  
		return nil
	}
	if m.Action != nil {
		if err := m.Action.Validate(formats); err != nil {
			if ve, ok := err.(*errors.Validation); ok {
				return ve.ValidateName("Action")
			}
			return err
		}
	}
	return nil
}
func (m *IdmACL) MarshalBinary() ([]byte, error) {
	if m == nil {
		return nil, nil
	}
	return swag.WriteJSON(m)
}