// 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"
)

// Domain Domain represents a remote domain
//
// swagger:model Domain
type Domain struct {

	// The hostname of the domain.
	// Example: example.org
	Domain string `json:"domain,omitempty"`

	// If the domain is blocked, what's the publicly-stated reason for the block.
	// Example: they smell
	PublicComment string `json:"public_comment,omitempty"`

	// Time at which this domain was silenced. Key will not be present on open domains.
	// Example: 2021-07-30T09:20:25+00:00
	SilencedAt string `json:"silenced_at,omitempty"`

	// Time at which this domain was suspended. Key will not be present on open domains.
	// Example: 2021-07-30T09:20:25+00:00
	SuspendedAt string `json:"suspended_at,omitempty"`
}

// Validate validates this domain
func (m *Domain) Validate(formats strfmt.Registry) error {
	return nil
}

// ContextValidate validates this domain based on context it is used
func (m *Domain) ContextValidate(ctx context.Context, formats strfmt.Registry) error {
	return nil
}

// MarshalBinary interface implementation
func (m *Domain) MarshalBinary() ([]byte, error) {
	if m == nil {
		return nil, nil
	}
	return swag.WriteJSON(m)
}

// UnmarshalBinary interface implementation
func (m *Domain) UnmarshalBinary(b []byte) error {
	var res Domain
	if err := swag.ReadJSON(b, &res); err != nil {
		return err
	}
	*m = res
	return nil
}
