{"modulePath":"github.com/orange-cloudfoundry/cli","version":"v7.1.0+incompatible","isLatest":true,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package cloudcontroller\n\nPackage cloudcontroller contains shared utilies between the V2 and V3 clients.\n\nThese sets of packages are still under development/pre-pre-pre...alpha. Use at your own risk! Functionality and design may change without warning.\n\nWhere are the clients?\n\nThese clients live in ccv2 and ccv3 packages. Each of them only works with the V2 and V3 api respectively.\n\n## Functions\n\n```go\nfunc DecodeJSON(raw []byte, v interface{}) error\n```\nDecodeJSON unmarshals JSON into the given object with the appropriate settings.\n\n## Types\n\n```go\ntype CloudControllerConnection struct {\n\tHTTPClient *http.Client\n\tUserAgent  string\n}\n```\nCloudControllerConnection represents a connection to the Cloud Controller server.\n\n```go\nfunc NewConnection(config Config) *CloudControllerConnection\n```\nNewConnection returns a new CloudControllerConnection with provided configuration.\n\n```go\nfunc (connection *CloudControllerConnection) Make(request *Request, passedResponse *Response) error\n```\nMake performs the request and parses the response.\n\n```go\ntype Config struct {\n\tDialTimeout       time.Duration\n\tSkipSSLValidation bool\n}\n```\nConfig is for configuring a CloudControllerConnection.\n\n```go\ntype Connection interface {\n\tMake(request *Request, passedResponse *Response) error\n}\n```\nConnection creates and executes http requests\n\n```go\ntype Pipebomb struct {\n\tio.ReadCloser\n}\n```\nPipebomb is a wrapper around an io.Pipe's io.ReadCloser that turns it into a ReadSeeker that errors on Seek calls. This is designed to prevent the caller from rereading the body multiple times.\n\n```go\nfunc NewPipeBomb() (*Pipebomb, io.WriteCloser)\n```\nNewPipeBomb returns an io.WriteCloser that can be used to stream data to a the Pipebomb.\n\n```go\nfunc (*Pipebomb) Seek(offset int64, whence int) (int64, error)\n```\nSeek returns a PipeSeekError; allowing the top level calling function to handle the retry instead of seeking back to the beginning of the Reader.\n\n```go\ntype Request struct {\n\t*http.Request\n\t// contains filtered or unexported fields\n}\n```\nRequest represents the request of the cloud controller.\n\n```go\nfunc NewRequest(request *http.Request, body io.ReadSeeker) *Request\n```\n\n```go\nfunc (r *Request) ResetBody() error\n```\n\n```go\ntype Response struct {\n\t// DecodeJSONResponseInto represents the resource entity type that is\n\t// expected in the response JSON.\n\tDecodeJSONResponseInto interface{}\n\n\t// RawResponse represents the response body.\n\tRawResponse []byte\n\n\t// Warnings represents warnings parsed from the custom warnings headers of a\n\t// Cloud Controller response.\n\tWarnings []string\n\n\t// HTTPResponse represents the HTTP response object.\n\tHTTPResponse *http.Response\n\n\t// ResourceLocationURL represents the Location header value\n\tResourceLocationURL string\n}\n```\nResponse represents a Cloud Controller response object.\n\n","path":"github.com/orange-cloudfoundry/cli/api/cloudcontroller","name":"cloudcontroller","synopsis":"Package cloudcontroller contains shared utilies between the V2 and V3 clients.","isRedistributable":true}
