Documentation ¶
Index ¶
- Constants
- type FakeHttpClient
- func (fhc *FakeHttpClient) CheckForHttpResponseErrors(data []byte) error
- func (fhc *FakeHttpClient) DoRawHttpRequest(path string, requestType string, requestBody *bytes.Buffer) ([]byte, int, error)
- func (fhc *FakeHttpClient) DoRawHttpRequestWithObjectFilter(path string, filters string, requestType string, requestBody *bytes.Buffer) ([]byte, int, error)
- func (fhc *FakeHttpClient) DoRawHttpRequestWithObjectFilterAndObjectMask(path string, masks []string, filters string, requestType string, ...) ([]byte, int, error)
- func (fhc *FakeHttpClient) DoRawHttpRequestWithObjectMask(path string, masks []string, requestType string, requestBody *bytes.Buffer) ([]byte, int, error)
- func (fhc *FakeHttpClient) GenerateRequestBody(templateData interface{}) (*bytes.Buffer, error)
- func (fhc *FakeHttpClient) HasErrors(body map[string]interface{}) error
- type FakeSoftLayerClient
- func (fslc *FakeSoftLayerClient) GetHttpClient() softlayer.HttpClient
- func (fslc *FakeSoftLayerClient) GetService(serviceName string) (softlayer.Service, error)
- func (fslc *FakeSoftLayerClient) GetSoftLayer_Account_Service() (softlayer.SoftLayer_Account_Service, error)
- func (fslc *FakeSoftLayerClient) GetSoftLayer_Billing_Item_Cancellation_Request_Service() (softlayer.SoftLayer_Billing_Item_Cancellation_Request_Service, error)
- func (fslc *FakeSoftLayerClient) GetSoftLayer_Billing_Item_Service() (softlayer.SoftLayer_Billing_Item_Service, error)
- func (fslc *FakeSoftLayerClient) GetSoftLayer_Dns_Domain_ResourceRecord_Service() (softlayer.SoftLayer_Dns_Domain_ResourceRecord_Service, error)
- func (fslc *FakeSoftLayerClient) GetSoftLayer_Dns_Domain_Service() (softlayer.SoftLayer_Dns_Domain_Service, error)
- func (fslc *FakeSoftLayerClient) GetSoftLayer_Hardware_Service() (softlayer.SoftLayer_Hardware_Service, error)
- func (fslc *FakeSoftLayerClient) GetSoftLayer_Network_Storage_Allowed_Host_Service() (softlayer.SoftLayer_Network_Storage_Allowed_Host_Service, error)
- func (fslc *FakeSoftLayerClient) GetSoftLayer_Network_Storage_Service() (softlayer.SoftLayer_Network_Storage_Service, error)
- func (fslc *FakeSoftLayerClient) GetSoftLayer_Product_Order_Service() (softlayer.SoftLayer_Product_Order_Service, error)
- func (fslc *FakeSoftLayerClient) GetSoftLayer_Product_Package_Service() (softlayer.SoftLayer_Product_Package_Service, error)
- func (fslc *FakeSoftLayerClient) GetSoftLayer_Security_Ssh_Key_Service() (softlayer.SoftLayer_Security_Ssh_Key_Service, error)
- func (fslc *FakeSoftLayerClient) GetSoftLayer_Virtual_Disk_Image_Service() (softlayer.SoftLayer_Virtual_Disk_Image_Service, error)
- func (fslc *FakeSoftLayerClient) GetSoftLayer_Virtual_Guest_Block_Device_Template_Group_Service() (softlayer.SoftLayer_Virtual_Guest_Block_Device_Template_Group_Service, error)
- func (fslc *FakeSoftLayerClient) GetSoftLayer_Virtual_Guest_Service() (softlayer.SoftLayer_Virtual_Guest_Service, error)
Constants ¶
View Source
const ( SOFTLAYER_API_URL = "api.softlayer.com/rest/v3" TEMPLATE_ROOT_PATH = "templates" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FakeHttpClient ¶ added in v0.5.0
type FakeHttpClient struct { Username string Password string DoRawHttpRequestInt int DoRawHttpRequestError error DoRawHttpRequestResponse []byte DoRawHttpRequestResponses [][]byte DoRawHttpRequestResponsesCount int DoRawHttpRequestResponsesIndex int //DoRawHttpRequest DoRawHttpRequestPath string DoRawHttpRequestRequestType string DoRawHttpRequestRequestBody *bytes.Buffer //DoRawHttpRequestWithObject DoRawHttpRequestWithObjectMaskPath string DoRawHttpRequestWithObjectMaskMasks []string DoRawHttpRequestWithObjectMaskRequestType string DoRawHttpRequestWithObjectMaskRequestBody *bytes.Buffer //DoRawHttpRequestWithObjectFilter DoRawHttpRequestWithObjectFilterPath string DoRawHttpRequestWithObjectFilterFilters string DoRawHttpRequestWithObjectFilterRequestType string DoRawHttpRequestWithObjectFilterRequestBody *bytes.Buffer //DoRawHttpRequestWithObjectFilterAndObjectMask DoRawHttpRequestWithObjectFilterAndObjectMaskPath string DoRawHttpRequestWithObjectFilterAndObjectMaskMasks []string DoRawHttpRequestWithObjectFilterAndObjectMaskFilters string DoRawHttpRequestWithObjectFilterAndObjectMaskRequestType string DoRawHttpRequestWithObjectFilterAndObjectMaskRequestBody *bytes.Buffer //GenerateRequest GenerateRequestBodyTemplateData interface{} GenerateRequestBodyBuffer *bytes.Buffer GenerateRequestBodyError error //HasErrors HasErrorsBody map[string]interface{} HasErrorsError error //CheclForHttpResponseErrors CheckForHttpResponseErrorsData []byte CheckForHttpResponseErrorsError error }
func NewFakeHttpClient ¶ added in v0.5.0
func NewFakeHttpClient(username, Password string) *FakeHttpClient
func (*FakeHttpClient) CheckForHttpResponseErrors ¶ added in v0.5.0
func (fhc *FakeHttpClient) CheckForHttpResponseErrors(data []byte) error
func (*FakeHttpClient) DoRawHttpRequest ¶ added in v0.5.0
func (*FakeHttpClient) DoRawHttpRequestWithObjectFilter ¶ added in v0.5.0
func (*FakeHttpClient) DoRawHttpRequestWithObjectFilterAndObjectMask ¶ added in v0.5.0
func (*FakeHttpClient) DoRawHttpRequestWithObjectMask ¶ added in v0.5.0
func (*FakeHttpClient) GenerateRequestBody ¶ added in v0.5.0
func (fhc *FakeHttpClient) GenerateRequestBody(templateData interface{}) (*bytes.Buffer, error)
func (*FakeHttpClient) HasErrors ¶ added in v0.5.0
func (fhc *FakeHttpClient) HasErrors(body map[string]interface{}) error
type FakeSoftLayerClient ¶
type FakeSoftLayerClient struct { Username string ApiKey string TemplatePath string SoftLayerServices map[string]softlayer.Service FakeHttpClient *FakeHttpClient }
func NewFakeSoftLayerClient ¶
func NewFakeSoftLayerClient(username, apiKey string) *FakeSoftLayerClient
func (*FakeSoftLayerClient) GetHttpClient ¶ added in v0.5.0
func (fslc *FakeSoftLayerClient) GetHttpClient() softlayer.HttpClient
func (*FakeSoftLayerClient) GetService ¶
func (fslc *FakeSoftLayerClient) GetService(serviceName string) (softlayer.Service, error)
func (*FakeSoftLayerClient) GetSoftLayer_Account_Service ¶
func (fslc *FakeSoftLayerClient) GetSoftLayer_Account_Service() (softlayer.SoftLayer_Account_Service, error)
func (*FakeSoftLayerClient) GetSoftLayer_Billing_Item_Cancellation_Request_Service ¶ added in v0.1.0
func (fslc *FakeSoftLayerClient) GetSoftLayer_Billing_Item_Cancellation_Request_Service() (softlayer.SoftLayer_Billing_Item_Cancellation_Request_Service, error)
func (*FakeSoftLayerClient) GetSoftLayer_Billing_Item_Service ¶ added in v0.6.0
func (fslc *FakeSoftLayerClient) GetSoftLayer_Billing_Item_Service() (softlayer.SoftLayer_Billing_Item_Service, error)
func (*FakeSoftLayerClient) GetSoftLayer_Dns_Domain_ResourceRecord_Service ¶ added in v0.4.0
func (fslc *FakeSoftLayerClient) GetSoftLayer_Dns_Domain_ResourceRecord_Service() (softlayer.SoftLayer_Dns_Domain_ResourceRecord_Service, error)
func (*FakeSoftLayerClient) GetSoftLayer_Dns_Domain_Service ¶ added in v0.4.0
func (fslc *FakeSoftLayerClient) GetSoftLayer_Dns_Domain_Service() (softlayer.SoftLayer_Dns_Domain_Service, error)
func (*FakeSoftLayerClient) GetSoftLayer_Hardware_Service ¶ added in v0.2.0
func (fslc *FakeSoftLayerClient) GetSoftLayer_Hardware_Service() (softlayer.SoftLayer_Hardware_Service, error)
func (*FakeSoftLayerClient) GetSoftLayer_Network_Storage_Allowed_Host_Service ¶ added in v0.3.0
func (fslc *FakeSoftLayerClient) GetSoftLayer_Network_Storage_Allowed_Host_Service() (softlayer.SoftLayer_Network_Storage_Allowed_Host_Service, error)
func (*FakeSoftLayerClient) GetSoftLayer_Network_Storage_Service ¶ added in v0.1.0
func (fslc *FakeSoftLayerClient) GetSoftLayer_Network_Storage_Service() (softlayer.SoftLayer_Network_Storage_Service, error)
func (*FakeSoftLayerClient) GetSoftLayer_Product_Order_Service ¶ added in v0.1.0
func (fslc *FakeSoftLayerClient) GetSoftLayer_Product_Order_Service() (softlayer.SoftLayer_Product_Order_Service, error)
func (*FakeSoftLayerClient) GetSoftLayer_Product_Package_Service ¶ added in v0.1.0
func (fslc *FakeSoftLayerClient) GetSoftLayer_Product_Package_Service() (softlayer.SoftLayer_Product_Package_Service, error)
func (*FakeSoftLayerClient) GetSoftLayer_Security_Ssh_Key_Service ¶
func (fslc *FakeSoftLayerClient) GetSoftLayer_Security_Ssh_Key_Service() (softlayer.SoftLayer_Security_Ssh_Key_Service, error)
func (*FakeSoftLayerClient) GetSoftLayer_Virtual_Disk_Image_Service ¶ added in v0.0.2
func (fslc *FakeSoftLayerClient) GetSoftLayer_Virtual_Disk_Image_Service() (softlayer.SoftLayer_Virtual_Disk_Image_Service, error)
func (*FakeSoftLayerClient) GetSoftLayer_Virtual_Guest_Block_Device_Template_Group_Service ¶ added in v0.1.0
func (fslc *FakeSoftLayerClient) GetSoftLayer_Virtual_Guest_Block_Device_Template_Group_Service() (softlayer.SoftLayer_Virtual_Guest_Block_Device_Template_Group_Service, error)
func (*FakeSoftLayerClient) GetSoftLayer_Virtual_Guest_Service ¶
func (fslc *FakeSoftLayerClient) GetSoftLayer_Virtual_Guest_Service() (softlayer.SoftLayer_Virtual_Guest_Service, error)
Click to show internal directories.
Click to hide internal directories.