// Code generated by go-swagger; DO NOT EDIT.

package signed_in_user

// This file was generated by the swagger tool.
// Editing this file might prove futile when you re-run the swagger generate command

import (
	"context"
	"net/http"
	"time"

	"github.com/go-openapi/errors"
	"github.com/go-openapi/runtime"
	cr "github.com/go-openapi/runtime/client"
	"github.com/go-openapi/strfmt"
)

// NewUnstarDashboardParams creates a new UnstarDashboardParams object,
// with the default timeout for this client.
//
// Default values are not hydrated, since defaults are normally applied by the API server side.
//
// To enforce default values in parameter, use SetDefaults or WithDefaults.
func NewUnstarDashboardParams() *UnstarDashboardParams {
	return &UnstarDashboardParams{
		timeout: cr.DefaultTimeout,
	}
}

// NewUnstarDashboardParamsWithTimeout creates a new UnstarDashboardParams object
// with the ability to set a timeout on a request.
func NewUnstarDashboardParamsWithTimeout(timeout time.Duration) *UnstarDashboardParams {
	return &UnstarDashboardParams{
		timeout: timeout,
	}
}

// NewUnstarDashboardParamsWithContext creates a new UnstarDashboardParams object
// with the ability to set a context for a request.
func NewUnstarDashboardParamsWithContext(ctx context.Context) *UnstarDashboardParams {
	return &UnstarDashboardParams{
		Context: ctx,
	}
}

// NewUnstarDashboardParamsWithHTTPClient creates a new UnstarDashboardParams object
// with the ability to set a custom HTTPClient for a request.
func NewUnstarDashboardParamsWithHTTPClient(client *http.Client) *UnstarDashboardParams {
	return &UnstarDashboardParams{
		HTTPClient: client,
	}
}

/*
UnstarDashboardParams contains all the parameters to send to the API endpoint

	for the unstar dashboard operation.

	Typically these are written to a http.Request.
*/
type UnstarDashboardParams struct {

	// DashboardID.
	DashboardID string

	timeout    time.Duration
	Context    context.Context
	HTTPClient *http.Client
}

// WithDefaults hydrates default values in the unstar dashboard params (not the query body).
//
// All values with no default are reset to their zero value.
func (o *UnstarDashboardParams) WithDefaults() *UnstarDashboardParams {
	o.SetDefaults()
	return o
}

// SetDefaults hydrates default values in the unstar dashboard params (not the query body).
//
// All values with no default are reset to their zero value.
func (o *UnstarDashboardParams) SetDefaults() {
	// no default values defined for this parameter
}

// WithTimeout adds the timeout to the unstar dashboard params
func (o *UnstarDashboardParams) WithTimeout(timeout time.Duration) *UnstarDashboardParams {
	o.SetTimeout(timeout)
	return o
}

// SetTimeout adds the timeout to the unstar dashboard params
func (o *UnstarDashboardParams) SetTimeout(timeout time.Duration) {
	o.timeout = timeout
}

// WithContext adds the context to the unstar dashboard params
func (o *UnstarDashboardParams) WithContext(ctx context.Context) *UnstarDashboardParams {
	o.SetContext(ctx)
	return o
}

// SetContext adds the context to the unstar dashboard params
func (o *UnstarDashboardParams) SetContext(ctx context.Context) {
	o.Context = ctx
}

// WithHTTPClient adds the HTTPClient to the unstar dashboard params
func (o *UnstarDashboardParams) WithHTTPClient(client *http.Client) *UnstarDashboardParams {
	o.SetHTTPClient(client)
	return o
}

// SetHTTPClient adds the HTTPClient to the unstar dashboard params
func (o *UnstarDashboardParams) SetHTTPClient(client *http.Client) {
	o.HTTPClient = client
}

// WithDashboardID adds the dashboardID to the unstar dashboard params
func (o *UnstarDashboardParams) WithDashboardID(dashboardID string) *UnstarDashboardParams {
	o.SetDashboardID(dashboardID)
	return o
}

// SetDashboardID adds the dashboardId to the unstar dashboard params
func (o *UnstarDashboardParams) SetDashboardID(dashboardID string) {
	o.DashboardID = dashboardID
}

// WriteToRequest writes these params to a swagger request
func (o *UnstarDashboardParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error {

	if err := r.SetTimeout(o.timeout); err != nil {
		return err
	}
	var res []error

	// path param dashboard_id
	if err := r.SetPathParam("dashboard_id", o.DashboardID); err != nil {
		return err
	}

	if len(res) > 0 {
		return errors.CompositeValidationError(res...)
	}
	return nil
}
