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

package federation

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

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

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

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

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

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

	for the s2s featured collection get operation.

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

	/* Username.

	   Account name of the user
	*/
	Username string

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

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

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

// WithTimeout adds the timeout to the s2s featured collection get params
func (o *S2sFeaturedCollectionGetParams) WithTimeout(timeout time.Duration) *S2sFeaturedCollectionGetParams {
	o.SetTimeout(timeout)
	return o
}

// SetTimeout adds the timeout to the s2s featured collection get params
func (o *S2sFeaturedCollectionGetParams) SetTimeout(timeout time.Duration) {
	o.timeout = timeout
}

// WithContext adds the context to the s2s featured collection get params
func (o *S2sFeaturedCollectionGetParams) WithContext(ctx context.Context) *S2sFeaturedCollectionGetParams {
	o.SetContext(ctx)
	return o
}

// SetContext adds the context to the s2s featured collection get params
func (o *S2sFeaturedCollectionGetParams) SetContext(ctx context.Context) {
	o.Context = ctx
}

// WithHTTPClient adds the HTTPClient to the s2s featured collection get params
func (o *S2sFeaturedCollectionGetParams) WithHTTPClient(client *http.Client) *S2sFeaturedCollectionGetParams {
	o.SetHTTPClient(client)
	return o
}

// SetHTTPClient adds the HTTPClient to the s2s featured collection get params
func (o *S2sFeaturedCollectionGetParams) SetHTTPClient(client *http.Client) {
	o.HTTPClient = client
}

// WithUsername adds the username to the s2s featured collection get params
func (o *S2sFeaturedCollectionGetParams) WithUsername(username string) *S2sFeaturedCollectionGetParams {
	o.SetUsername(username)
	return o
}

// SetUsername adds the username to the s2s featured collection get params
func (o *S2sFeaturedCollectionGetParams) SetUsername(username string) {
	o.Username = username
}

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

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

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

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