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

package tenant_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"
	"github.com/go-openapi/strfmt"
)

// NewTenantServiceGetParams creates a new TenantServiceGetParams 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 NewTenantServiceGetParams() *TenantServiceGetParams {
	return &TenantServiceGetParams{
		timeout: cr.DefaultTimeout,
	}
}

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

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

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

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

	for the tenant service get operation.

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

	/* ID.

	   Tenant ID.
	*/
	ID string

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

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

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

// WithTimeout adds the timeout to the tenant service get params
func (o *TenantServiceGetParams) WithTimeout(timeout time.Duration) *TenantServiceGetParams {
	o.SetTimeout(timeout)
	return o
}

// SetTimeout adds the timeout to the tenant service get params
func (o *TenantServiceGetParams) SetTimeout(timeout time.Duration) {
	o.timeout = timeout
}

// WithContext adds the context to the tenant service get params
func (o *TenantServiceGetParams) WithContext(ctx context.Context) *TenantServiceGetParams {
	o.SetContext(ctx)
	return o
}

// SetContext adds the context to the tenant service get params
func (o *TenantServiceGetParams) SetContext(ctx context.Context) {
	o.Context = ctx
}

// WithHTTPClient adds the HTTPClient to the tenant service get params
func (o *TenantServiceGetParams) WithHTTPClient(client *http.Client) *TenantServiceGetParams {
	o.SetHTTPClient(client)
	return o
}

// SetHTTPClient adds the HTTPClient to the tenant service get params
func (o *TenantServiceGetParams) SetHTTPClient(client *http.Client) {
	o.HTTPClient = client
}

// WithID adds the id to the tenant service get params
func (o *TenantServiceGetParams) WithID(id string) *TenantServiceGetParams {
	o.SetID(id)
	return o
}

// SetID adds the id to the tenant service get params
func (o *TenantServiceGetParams) SetID(id string) {
	o.ID = id
}

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

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

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

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