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

// Billing20201105PackageItemSelection PackageItemSelection contains the selection information of a given Package Item Option
// for a Package Item. Optionally, it contains a quantity.
//
// swagger:model billing_20201105PackageItemSelection
type Billing20201105PackageItemSelection struct {

	// item_key is the key of the Package Item this selection represents.
	ItemKey string `json:"item_key,omitempty"`

	// option_key is the key of the Package Item Option for this selection.
	OptionKey string `json:"option_key,omitempty"`

	// quantity is optionally the given amount of a PackageItem required.
	Quantity int32 `json:"quantity,omitempty"`
}

// Validate validates this billing 20201105 package item selection
func (m *Billing20201105PackageItemSelection) Validate(formats strfmt.Registry) error {
	return nil
}

// ContextValidate validates this billing 20201105 package item selection based on context it is used
func (m *Billing20201105PackageItemSelection) ContextValidate(ctx context.Context, formats strfmt.Registry) error {
	return nil
}

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

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