github.com/sap/cf-mta-plugin@v2.6.3+incompatible/clients/mtaclient/operations/get_mta_operation_log_content_parameters.go (about)

     1  // Code generated by go-swagger; DO NOT EDIT.
     2  
     3  package operations
     4  
     5  // This file was generated by the swagger tool.
     6  // Editing this file might prove futile when you re-run the swagger generate command
     7  
     8  import (
     9  	"net/http"
    10  	"time"
    11  
    12  	"golang.org/x/net/context"
    13  
    14  	"github.com/go-openapi/errors"
    15  	"github.com/go-openapi/runtime"
    16  	cr "github.com/go-openapi/runtime/client"
    17  
    18  	strfmt "github.com/go-openapi/strfmt"
    19  )
    20  
    21  // NewGetMtaOperationLogContentParams creates a new GetMtaOperationLogContentParams object
    22  // with the default values initialized.
    23  func NewGetMtaOperationLogContentParams() *GetMtaOperationLogContentParams {
    24  	var ()
    25  	return &GetMtaOperationLogContentParams{
    26  
    27  		timeout: cr.DefaultTimeout,
    28  	}
    29  }
    30  
    31  // NewGetMtaOperationLogContentParamsWithTimeout creates a new GetMtaOperationLogContentParams object
    32  // with the default values initialized, and the ability to set a timeout on a request
    33  func NewGetMtaOperationLogContentParamsWithTimeout(timeout time.Duration) *GetMtaOperationLogContentParams {
    34  	var ()
    35  	return &GetMtaOperationLogContentParams{
    36  
    37  		timeout: timeout,
    38  	}
    39  }
    40  
    41  // NewGetMtaOperationLogContentParamsWithContext creates a new GetMtaOperationLogContentParams object
    42  // with the default values initialized, and the ability to set a context for a request
    43  func NewGetMtaOperationLogContentParamsWithContext(ctx context.Context) *GetMtaOperationLogContentParams {
    44  	var ()
    45  	return &GetMtaOperationLogContentParams{
    46  
    47  		Context: ctx,
    48  	}
    49  }
    50  
    51  // NewGetMtaOperationLogContentParamsWithHTTPClient creates a new GetMtaOperationLogContentParams object
    52  // with the default values initialized, and the ability to set a custom HTTPClient for a request
    53  func NewGetMtaOperationLogContentParamsWithHTTPClient(client *http.Client) *GetMtaOperationLogContentParams {
    54  	var ()
    55  	return &GetMtaOperationLogContentParams{
    56  		HTTPClient: client,
    57  	}
    58  }
    59  
    60  /*GetMtaOperationLogContentParams contains all the parameters to send to the API endpoint
    61  for the get mta operation log content operation typically these are written to a http.Request
    62  */
    63  type GetMtaOperationLogContentParams struct {
    64  
    65  	/*LogID*/
    66  	LogID string
    67  	/*OperationID*/
    68  	OperationID string
    69  
    70  	timeout    time.Duration
    71  	Context    context.Context
    72  	HTTPClient *http.Client
    73  }
    74  
    75  // WithTimeout adds the timeout to the get mta operation log content params
    76  func (o *GetMtaOperationLogContentParams) WithTimeout(timeout time.Duration) *GetMtaOperationLogContentParams {
    77  	o.SetTimeout(timeout)
    78  	return o
    79  }
    80  
    81  // SetTimeout adds the timeout to the get mta operation log content params
    82  func (o *GetMtaOperationLogContentParams) SetTimeout(timeout time.Duration) {
    83  	o.timeout = timeout
    84  }
    85  
    86  // WithContext adds the context to the get mta operation log content params
    87  func (o *GetMtaOperationLogContentParams) WithContext(ctx context.Context) *GetMtaOperationLogContentParams {
    88  	o.SetContext(ctx)
    89  	return o
    90  }
    91  
    92  // SetContext adds the context to the get mta operation log content params
    93  func (o *GetMtaOperationLogContentParams) SetContext(ctx context.Context) {
    94  	o.Context = ctx
    95  }
    96  
    97  // WithHTTPClient adds the HTTPClient to the get mta operation log content params
    98  func (o *GetMtaOperationLogContentParams) WithHTTPClient(client *http.Client) *GetMtaOperationLogContentParams {
    99  	o.SetHTTPClient(client)
   100  	return o
   101  }
   102  
   103  // SetHTTPClient adds the HTTPClient to the get mta operation log content params
   104  func (o *GetMtaOperationLogContentParams) SetHTTPClient(client *http.Client) {
   105  	o.HTTPClient = client
   106  }
   107  
   108  // WithLogID adds the logID to the get mta operation log content params
   109  func (o *GetMtaOperationLogContentParams) WithLogID(logID string) *GetMtaOperationLogContentParams {
   110  	o.SetLogID(logID)
   111  	return o
   112  }
   113  
   114  // SetLogID adds the logId to the get mta operation log content params
   115  func (o *GetMtaOperationLogContentParams) SetLogID(logID string) {
   116  	o.LogID = logID
   117  }
   118  
   119  // WithOperationID adds the operationID to the get mta operation log content params
   120  func (o *GetMtaOperationLogContentParams) WithOperationID(operationID string) *GetMtaOperationLogContentParams {
   121  	o.SetOperationID(operationID)
   122  	return o
   123  }
   124  
   125  // SetOperationID adds the operationId to the get mta operation log content params
   126  func (o *GetMtaOperationLogContentParams) SetOperationID(operationID string) {
   127  	o.OperationID = operationID
   128  }
   129  
   130  // WriteToRequest writes these params to a swagger request
   131  func (o *GetMtaOperationLogContentParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error {
   132  
   133  	if err := r.SetTimeout(o.timeout); err != nil {
   134  		return err
   135  	}
   136  	var res []error
   137  
   138  	// path param logId
   139  	if err := r.SetPathParam("logId", o.LogID); err != nil {
   140  		return err
   141  	}
   142  
   143  	// path param operationId
   144  	if err := r.SetPathParam("operationId", o.OperationID); err != nil {
   145  		return err
   146  	}
   147  
   148  	if len(res) > 0 {
   149  		return errors.CompositeValidationError(res...)
   150  	}
   151  	return nil
   152  }