1// Copyright (c) 2016, 2018, 2019, Oracle and/or its affiliates. All rights reserved.
2// Code generated. DO NOT EDIT.
3
4package core
5
6import (
7	"github.com/oracle/oci-go-sdk/common"
8	"net/http"
9)
10
11// ListServicesRequest wrapper for the ListServices operation
12type ListServicesRequest struct {
13
14	// For list pagination. The maximum number of results per page, or items to return in a paginated
15	// "List" call. For important details about how pagination works, see
16	// List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine).
17	// Example: `50`
18	Limit *int `mandatory:"false" contributesTo:"query" name:"limit"`
19
20	// For list pagination. The value of the `opc-next-page` response header from the previous "List"
21	// call. For important details about how pagination works, see
22	// List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine).
23	Page *string `mandatory:"false" contributesTo:"query" name:"page"`
24
25	// Unique Oracle-assigned identifier for the request.
26	// If you need to contact Oracle about a particular request, please provide the request ID.
27	OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"`
28
29	// Metadata about the request. This information will not be transmitted to the service, but
30	// represents information that the SDK will consume to drive retry behavior.
31	RequestMetadata common.RequestMetadata
32}
33
34func (request ListServicesRequest) String() string {
35	return common.PointerString(request)
36}
37
38// HTTPRequest implements the OCIRequest interface
39func (request ListServicesRequest) HTTPRequest(method, path string) (http.Request, error) {
40	return common.MakeDefaultHTTPRequestWithTaggedStruct(method, path, request)
41}
42
43// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy.
44func (request ListServicesRequest) RetryPolicy() *common.RetryPolicy {
45	return request.RequestMetadata.RetryPolicy
46}
47
48// ListServicesResponse wrapper for the ListServices operation
49type ListServicesResponse struct {
50
51	// The underlying http response
52	RawResponse *http.Response
53
54	// A list of []Service instances
55	Items []Service `presentIn:"body"`
56
57	// For list pagination. When this header appears in the response, additional pages
58	// of results remain. For important details about how pagination works, see
59	// List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine).
60	OpcNextPage *string `presentIn:"header" name:"opc-next-page"`
61
62	// Unique Oracle-assigned identifier for the request. If you need to contact
63	// Oracle about a particular request, please provide the request ID.
64	OpcRequestId *string `presentIn:"header" name:"opc-request-id"`
65}
66
67func (response ListServicesResponse) String() string {
68	return common.PointerString(response)
69}
70
71// HTTPResponse implements the OCIResponse interface
72func (response ListServicesResponse) HTTPResponse() *http.Response {
73	return response.RawResponse
74}
75