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

package pipeline_service

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

	strfmt "github.com/go-openapi/strfmt"
)

// NewGetPipelineVersionParams creates a new GetPipelineVersionParams object
// with the default values initialized.
func NewGetPipelineVersionParams() *GetPipelineVersionParams {
	var ()
	return &GetPipelineVersionParams{

		timeout: cr.DefaultTimeout,
	}
}

// NewGetPipelineVersionParamsWithTimeout creates a new GetPipelineVersionParams object
// with the default values initialized, and the ability to set a timeout on a request
func NewGetPipelineVersionParamsWithTimeout(timeout time.Duration) *GetPipelineVersionParams {
	var ()
	return &GetPipelineVersionParams{

		timeout: timeout,
	}
}

// NewGetPipelineVersionParamsWithContext creates a new GetPipelineVersionParams object
// with the default values initialized, and the ability to set a context for a request
func NewGetPipelineVersionParamsWithContext(ctx context.Context) *GetPipelineVersionParams {
	var ()
	return &GetPipelineVersionParams{

		Context: ctx,
	}
}

// NewGetPipelineVersionParamsWithHTTPClient creates a new GetPipelineVersionParams object
// with the default values initialized, and the ability to set a custom HTTPClient for a request
func NewGetPipelineVersionParamsWithHTTPClient(client *http.Client) *GetPipelineVersionParams {
	var ()
	return &GetPipelineVersionParams{
		HTTPClient: client,
	}
}

/*GetPipelineVersionParams contains all the parameters to send to the API endpoint
for the get pipeline version operation typically these are written to a http.Request
*/
type GetPipelineVersionParams struct {

	/*PipelineID
	  Required input. ID of the parent pipeline.

	*/
	PipelineID string
	/*PipelineVersionID
	  Required input. ID of the pipeline version to be retrieved.

	*/
	PipelineVersionID string

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

// WithTimeout adds the timeout to the get pipeline version params
func (o *GetPipelineVersionParams) WithTimeout(timeout time.Duration) *GetPipelineVersionParams {
	o.SetTimeout(timeout)
	return o
}

// SetTimeout adds the timeout to the get pipeline version params
func (o *GetPipelineVersionParams) SetTimeout(timeout time.Duration) {
	o.timeout = timeout
}

// WithContext adds the context to the get pipeline version params
func (o *GetPipelineVersionParams) WithContext(ctx context.Context) *GetPipelineVersionParams {
	o.SetContext(ctx)
	return o
}

// SetContext adds the context to the get pipeline version params
func (o *GetPipelineVersionParams) SetContext(ctx context.Context) {
	o.Context = ctx
}

// WithHTTPClient adds the HTTPClient to the get pipeline version params
func (o *GetPipelineVersionParams) WithHTTPClient(client *http.Client) *GetPipelineVersionParams {
	o.SetHTTPClient(client)
	return o
}

// SetHTTPClient adds the HTTPClient to the get pipeline version params
func (o *GetPipelineVersionParams) SetHTTPClient(client *http.Client) {
	o.HTTPClient = client
}

// WithPipelineID adds the pipelineID to the get pipeline version params
func (o *GetPipelineVersionParams) WithPipelineID(pipelineID string) *GetPipelineVersionParams {
	o.SetPipelineID(pipelineID)
	return o
}

// SetPipelineID adds the pipelineId to the get pipeline version params
func (o *GetPipelineVersionParams) SetPipelineID(pipelineID string) {
	o.PipelineID = pipelineID
}

// WithPipelineVersionID adds the pipelineVersionID to the get pipeline version params
func (o *GetPipelineVersionParams) WithPipelineVersionID(pipelineVersionID string) *GetPipelineVersionParams {
	o.SetPipelineVersionID(pipelineVersionID)
	return o
}

// SetPipelineVersionID adds the pipelineVersionId to the get pipeline version params
func (o *GetPipelineVersionParams) SetPipelineVersionID(pipelineVersionID string) {
	o.PipelineVersionID = pipelineVersionID
}

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

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

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

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

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